# Visual markup

**URL:** <https://discourse.citationstyles.org/t/visual-markup/798>\
**Category:** CSL Development\
**Created:** [December 7, 2009, 2:43am UTC](https://discourse.citationstyles.org/t/visual-markup/798 "2009-12-07T02:43:57Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Frank\_Bennett](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/frank_bennett/32/198_2.png) [@Frank\_Bennett](https://discourse.citationstyles.org/u/Frank_Bennett)\
**Post date:** [December 7, 2009, 2:43am UTC](https://discourse.citationstyles.org/t/visual-markup/798/1 "2009-12-07T02:43:57Z")

</div>

I’ve made a small change to the visual markup parser in citeproc-js.  
It formerly recognized an … tag span to designate text that  
should not be mangled. This worked fine for proper names, but:

- It is not HTML, and so would play poorly with a web UI, and
- It missed out another use case, for the “v.” in case names, for  
which both capitalization _and_ decorations should be suppressed.

I have adjusted the parser code to use …  
and … instead, for the two cases  
respectively. This should be workable for editing tools such as  
TinyMCE, and the citeproc-js parser is able transform the tags into  
whatever does the right thing for the current output mode.

I’ll be pushing the code tomorrow unless there are serious objections.

(cross-posted to citeproc-js)

Frank

---

<div class="post-metadata">

**Author:** ![Frank\_Bennett](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/frank_bennett/32/198_2.png) [@Frank\_Bennett](https://discourse.citationstyles.org/u/Frank_Bennett)\
**Post date:** [December 7, 2009, 3:39am UTC](https://discourse.citationstyles.org/t/visual-markup/798/2 "2009-12-07T03:39:45Z")

</div>

(relaying this to xbiblio-devel for further discussion)

> …
> 
> > - It missed out another use case, for the “v.” in case names, for  
> > which both capitalization _and_ decorations should be suppressed.
> > 
> > I have adjusted the parser code to use …  
> > and … instead, for the two cases  
> > respectively.
> 
> I’m not following the “decoration” use case here. In the csl-data  
> schema, I just have a single “protect” class, which corresponds to  
> BibTeX’s use of brackets. Why is that not enough?

There are two use cases. For concrete-ish examples …

If the following is produced using text-case=“sentence”, the proper  
name needs to be escaped for text mangling, but not for decorations:

_Metaphorical subtext in Bullshot Crummond_ …

My current markup in the data for this title would be:

Metaphorical Subtext in Bullshot Crummond

If the following is produced in any style, the “v.” needs to be  
escaped for decorations. Currently I also escape it for text  
mangling:

_Lessard v. Schmidt_ …

My current markup in the data for this title would be:

Lessard v. Schmidt

BibTeX cannot handle the second use case, but it doesn’t need to  
because it is never used to process legal citations (or if it is,  
users excuse the fact that it does not print them correctly).
