[sword-devel] Question about use of note elements

Karl Kleinpaste karl at kleinpaste.org
Fri Jul 20 11:46:13 MST 2012

Andrew Thule <thulester at gmail.com> writes:
> The Xiphos behavior complete perplexes me - how is *n%2B constructed?

The short answer: Xiphos displays whatever the engine filters give it.

The long answer: For many years the filters generated just "*n" for
footnotes and "*x" for xrefs, without per-element identifiers for the
"n=XYZ" markers often found in such notes.  Late last year or early this
year (I forget when), I introduced a change to provide the "n=XYZ"
content, and this is provided as part of *n or *x.  Providing this is
optional: See the context [right-click] menu, "Footnote/Cross-ref
Markers," default on.  It's a per-module option.  If your module
displays with "*n%2B", then your note is marked as item "n=%2B".

No, it isn't very pretty.  *n and *x were never all that pretty or
well-liked anyway.  The update at least provides the module-provided
identifiers.  There have been suggestions that the *n and *x themselves
be abandoned, in favor of just the n=XYZ marker by itself...except that
some modules provide footnotes without such markers.

Whatever differences you see in the other UIs, it's because they've
picked some behavior other than what the engine provides by default.

Also, side mention: If you see *n (whether or not followed by an
identifier), then what the engine found in the content was a footnote,
not an xref.  No UI should not express it as a cross-reference,
regardless of whether its content looks like a cross-reference.

> If a superscript is going to be generated, how can I influence that in
> the module?

Xiphos is one of the UIs that uses the "htmlhref" filters, which does
what I've described above.  The only influence a module producer has is
to decide whether "n=XYZ" is provided.  Also, the "xhtml" filters,
derived from the htmlhref filters, do the same thing at this time,
though their development may well diverge in the future.  I'm not aware
of any UI using the xhtml filters yet.  Xiphos might move to them in the
not too distant future; they are intended for projects like improved CSS
support that is not intended to be seen in the htmlhref filters.

Other filters sets, such as the RTF filters, behave differently, so
BibleCS (in particular) won't look the same.  BibleTime has subclassed
many filters for their own re-implementation, so that's in a totally
different world.

> This note with out a reference <note type="study">the light from…:
> Heb. between the light and between the darkness</note> is rendered in:
> Xiphos as superscript link "*n2" (with contents of the note treated as
> footnote) Bibletime as hover link * (with the contents of the note in
> a window to the left of the main text) Alkitab as a superscript 'a'
> (with the contents of the note visible in a column to the left of the
> main text)

If you see "*n2" in Xiphos, that means that the note is identified with
"n=2" in the note descriptor.  If Alkitab has chosen to display that
particular note as "a", then Alkitab's authors have chosen some other,
arbitrary note identification scheme.

> Doesn't this represent somewhat of a weakness with the OSIS standard?
> What exceptions can we have with respect to notes containing other
> elements, for example references with in notes? Doesn't it seems the
> module developer is at the mercy of client program a bit too much
> because of something of a lack of clarity on the part of the standard?

I hesitate to comment much, because I've been critical of OSIS to one
degree or another for years and still use only ThML in my own modules.
But nonetheless it is certainly true there is ambiguity in the standard
and widely varying implementation choice in the UIs.  Honestly, whether
you like it or not, Xiphos takes the most bland approach in this regard,
in that we have chosen not to depart from the filter-provided content,
delivering it straight up for display.

Well...exception to that: We brutalize the HTML pretty seriously in the
presence of Strongs and morphology content.  But that's because the
standard display [which is done purely in-line, and looks like "word
<1234> (n2-nsm)"] is visually offensive to most people, nearly
impossible to read.  Xiphos' brutalization provides for a stacked
display to separate the extra markup from the text content proper.  See
the Xiphos manual, section 3.9.


More information about the sword-devel mailing list