Discussion:
[sword-devel] OSIS markup for gen books and devotionals
Laurie Fooks
2014-08-26 23:44:58 UTC
Permalink
Hi

I am new to the list and to making sword modules - I am using OSIS
markup to produce sword modules in a couple of different languages for
the Bible, using osis sourced from the ebible ftp repository, and
creating lectionary/devotional and general books from print sources
(all copyrights being honored). I am using markup from the OSIS site
with adjustment as described in the Crosswire wiki.

I have attached 3 small test modules "TEST", "TEST2" and "TEST_CAL"
to demonstrate my use of the markup. I have also attached the source
markup. I am using sword 1.7.3 utilities - imp2ld for the devotionals
and xml2gbs for the gen books. All the markup in the test modules does
work in different sword front ends but none of the front end programs
are able to display all the markup.

Some things I need assistance with:

1. Internal linking - the pattern, "MODULE:DIV1.DIV2.DIV3" in the
Crosswire wiki does not work in any front end -
"MODULE:DIV1/DIV2/DIV3" works in Xiphos and BPBible and
"MODULE://DIV1/DIV2/DIV3" is needed for BibleTime and BibleTime-Mini.

Is there a "correct" OSIS markup, or does it depend on the front end?

2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?

3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?

These are examples. The attached test modules have fairly basic
markup, but no front end will display them all. I would appreciate
guidance on how I can adjust my markup to have all the markup
displayed ?

Thanks
Laurie
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.zip
Type: application/zip
Size: 20682 bytes
Desc: not available
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140827/d052bf89/attachment-0002.zip>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: testsource.zip
Type: application/zip
Size: 2327 bytes
Desc: not available
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140827/d052bf89/attachment-0003.zip>
Peter Von Kaehne
2014-08-27 09:00:43 UTC
Permalink
Hi,

Will need to look at your example files later.

Right now - the links are a long lasting bug bear of all of us. The wiki layout is the desired and correct one. The engine implementation of that is dodgy and needs fixing. We decided a while back to leave the wiki as it stands because that is the way it should be.

Paragraphs and line breaks - section and paragraphing work well for me, not sure what you mean.

Images work well on most frontends. Need to look at your examples to see where things went wrong. Later more

Peter
Laurie Fooks
2014-08-28 15:10:49 UTC
Permalink
Resending without attachments as it is queued

Thanks Peter,

I have attached another set of test mods and source with the <p> tags.

The paragraphs display correctly in Xiphos, BPBible and Xulsword but
not in BibleTime or BT-Mini or AndBible.

Really appreciate if you can look at my modules as to where I am going wrong ...

Is it possible that part of the prob may be that most genbooks have
historically used "ThML" and some front ends are geared towards that
markup?

Cheers
Laurie
Post by Peter Von Kaehne
Hi,
Will need to look at your example files later.
Right now - the links are a long lasting bug bear of all of us. The wiki
layout is the desired and correct one. The engine implementation of that is
dodgy and needs fixing. We decided a while back to leave the wiki as it
stands because that is the way it should be.
Paragraphs and line breaks - section and paragraphing work well for me, not
sure what you mean.
Images work well on most frontends. Need to look at your examples to see
where things went wrong. Later more
Peter
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Karl Kleinpaste
2014-08-28 15:42:45 UTC
Permalink
Post by Laurie Fooks
Is it possible that part of the prob may be that most genbooks have
historically used "ThML" and some front ends are geared towards that
markup?
$ cd ~/.sword/mods.d
$ grep -l ^DataPath.*genbook * | xargs grep ^SourceType | tr -d '\r' |
cut -f2 -d= | tr A-Z a-z | sort | uniq -c | sort
1 plain
1 plaintext
1 tei
29 osis
57 thml

Certainly there is a lot of ThML, but genbooks are no stranger to OSIS.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140828/d84a3366/attachment-0001.html>
laurie.fooks
2014-08-28 15:51:20 UTC
Permalink
Thanks Karl ... but not many, if any, use more than basic markup?

If I am chasing something which is not achievable, I'll drop it ...
Post by Karl Kleinpaste
Post by Laurie Fooks
Is it possible that part of the prob may be that most genbooks have
historically used "ThML" and some front ends are geared towards that
markup?
$ cd ~/.sword/mods.d
$ grep -l ^DataPath.*genbook * | xargs grep ^SourceType | tr -d '\r' |
cut -f2 -d= | tr A-Z a-z | sort | uniq -c | sort
1 plain
1 plaintext
1 tei
29 osis
57 thml
Certainly there is a lot of ThML, but genbooks are no stranger to OSIS.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140829/527e34c2/attachment.html>
David &quot;Judah's Shadow&quot; Blue
2014-08-27 12:10:44 UTC
Permalink
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am working on formatting poetry "correctly" in BibleTime (i.e. indenting, block formatting, etc). So using lg or l for merely the line breaks is a bad idea. Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test module in it. I don't recall though, if that was a commentary or a genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
Laurie Fooks
2014-08-27 21:52:50 UTC
Permalink
Thanks David,

Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.

Really appreciate if you can also look at the <figure> tag - BibleTime
/ BT-Mini show an indicator that there is an image, but is not
displaying the image. BibleTime does display images in ThML formatted
modules.

Cheers
Laurie
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am working
on formatting poetry "correctly" in BibleTime (i.e. indenting, block
formatting, etc). So using lg or l for merely the line breaks is a bad idea.
Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test
module in it. I don't recall though, if that was a commentary or a genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Nic Carter
2014-08-28 05:36:42 UTC
Permalink
Hi Laurie,

Some front-ends will apply some special formatting for poetry & you don't want that formatting for your modules, so don't mark it as poetry & you'll be fine :)
(PocketSword is an example, if you wanted to test on an iOS device.)

Thanks, ybic
Nic. :)
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
Really appreciate if you can also look at the <figure> tag - BibleTime
/ BT-Mini show an indicator that there is an image, but is not
displaying the image. BibleTime does display images in ThML formatted
modules.
Cheers
Laurie
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am working
on formatting poetry "correctly" in BibleTime (i.e. indenting, block
formatting, etc). So using lg or l for merely the line breaks is a bad idea.
Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test
module in it. I don't recall though, if that was a commentary or a genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Laurie Fooks
2014-08-28 05:51:00 UTC
Permalink
Thanks Nic

I certainly hope there will be a solution to paragraphs and line
displays, particularly for Android programs ... until then, I am stuck
with >lg><l> !!

I have PocketSword 1.45 on an Ipod and Iphone - Is there a way for it
to display general books?

Cheers
Laurie
Post by Nic Carter
Hi Laurie,
Some front-ends will apply some special formatting for poetry & you don't
want that formatting for your modules, so don't mark it as poetry & you'll
be fine :)
(PocketSword is an example, if you wanted to test on an iOS device.)
Thanks, ybic
Nic. :)
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
Really appreciate if you can also look at the <figure> tag - BibleTime
/ BT-Mini show an indicator that there is an image, but is not
displaying the image. BibleTime does display images in ThML formatted
modules.
Cheers
Laurie
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am working
on formatting poetry "correctly" in BibleTime (i.e. indenting, block
formatting, etc). So using lg or l for merely the line breaks is a bad idea.
Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test
module in it. I don't recall though, if that was a commentary or a genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Nic Carter
2014-08-28 05:55:10 UTC
Permalink
Ahh, no, sorry. Devotionals, commentaries, Bibles & dictionaries :)
Post by Laurie Fooks
Thanks Nic
I certainly hope there will be a solution to paragraphs and line
displays, particularly for Android programs ... until then, I am stuck
with >lg><l> !!
I have PocketSword 1.45 on an Ipod and Iphone - Is there a way for it
to display general books?
Cheers
Laurie
Post by Nic Carter
Hi Laurie,
Some front-ends will apply some special formatting for poetry & you don't
want that formatting for your modules, so don't mark it as poetry & you'll
be fine :)
(PocketSword is an example, if you wanted to test on an iOS device.)
Thanks, ybic
Nic. :)
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
Really appreciate if you can also look at the <figure> tag - BibleTime
/ BT-Mini show an indicator that there is an image, but is not
displaying the image. BibleTime does display images in ThML formatted
modules.
Cheers
Laurie
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am working
on formatting poetry "correctly" in BibleTime (i.e. indenting, block
formatting, etc). So using lg or l for merely the line breaks is a bad idea.
Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test
module in it. I don't recall though, if that was a commentary or a genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Laurie Fooks
2014-08-28 06:05:05 UTC
Permalink
Hi Nic

I just has a look at Psalms on PocketSword in a bible version using
<lg><l> markup -its great as it does display the <l level="2"> etc
tags to give the indenting. I don't see anything else unexpected ?
Did I miss something ... Is line spacing the same... it was hard to
tell? I would love to try my test mods on the PocketSword.

Cheers

Laurie
Post by Nic Carter
Hi Laurie,
Some front-ends will apply some special formatting for poetry & you don't
want that formatting for your modules, so don't mark it as poetry & you'll
be fine :)
(PocketSword is an example, if you wanted to test on an iOS device.)
Thanks, ybic
Nic. :)
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
Really appreciate if you can also look at the <figure> tag - BibleTime
/ BT-Mini show an indicator that there is an image, but is not
displaying the image. BibleTime does display images in ThML formatted
modules.
Cheers
Laurie
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am working
on formatting poetry "correctly" in BibleTime (i.e. indenting, block
formatting, etc). So using lg or l for merely the line breaks is a bad idea.
Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test
module in it. I don't recall though, if that was a commentary or a genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Nic Carter
2014-08-28 06:12:50 UTC
Permalink
Hi Laurie,

Try creating a pretend-Bible and put a bunch of your text all in Gen 1:1 & see how it looks. Marking something as poetry will automatically indent it a little in PocketSword & so you will be wasting some screen space for "normal" text when you're on a small screen...

If you have more PocketSword questions, how about you ask me off the list so as to not clog it up with specifics related to PS-only? :)

Thanks, ybic
Nic :)
Post by Laurie Fooks
Hi Nic
I just has a look at Psalms on PocketSword in a bible version using
<lg><l> markup -its great as it does display the <l level="2"> etc
tags to give the indenting. I don't see anything else unexpected ?
Did I miss something ... Is line spacing the same... it was hard to
tell? I would love to try my test mods on the PocketSword.
Cheers
Laurie
Post by Nic Carter
Hi Laurie,
Some front-ends will apply some special formatting for poetry & you don't
want that formatting for your modules, so don't mark it as poetry & you'll
be fine :)
(PocketSword is an example, if you wanted to test on an iOS device.)
Thanks, ybic
Nic. :)
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
Really appreciate if you can also look at the <figure> tag - BibleTime
/ BT-Mini show an indicator that there is an image, but is not
displaying the image. BibleTime does display images in ThML formatted
modules.
Cheers
Laurie
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am working
on formatting poetry "correctly" in BibleTime (i.e. indenting, block
formatting, etc). So using lg or l for merely the line breaks is a bad idea.
Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test
module in it. I don't recall though, if that was a commentary or a genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Laurie Fooks
2014-08-28 15:08:02 UTC
Permalink
Looking at the OSIS manual again, I tried the milestone line break -
<milestone type="line"/> and it works, albeit differently on different
front ends e.g. BT displays each break and Xiphos strips extra
linebreaks inserted to give a blank line.

For the BT devels - I have also just found that the images are
displayed in BibleTime 2.10.1 on Ubuntu 14.04 (64bit) - The same
version under Windows 7 (64bit) does not display the images ?? The
downside is the linux version does not handle the internal links :(


______________________________________________
Post by David &quot;Judah's Shadow&quot; Blue
Post by David &quot;Judah's Shadow&quot; Blue
Post by David &quot;Judah's Shadow&quot; Blue
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
David &quot;Judah's Shadow&quot; Blue
2014-09-06 11:15:58 UTC
Permalink
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
To supplement the answers already given, as far as OSIS is concerned, the reason that <lg><l> tags are suggested to not be used for line or page breaks is that OSIS is a semantic language meaning you are tagging what something /is/ not how it looks. This I think is why <p> tags aren't having the desired effect either. Unlike in HTML, <p> is specifically for delineating paragraphs conceptually. An empty paragraph doesn't produce a blank line like in HTML. That is a side effect of how block-level display tags are rendered in HTML not because of something universal to <p>. As for why you want to mark things semantically rather than presentationally, someday there might be a front-end for visually impaired persons (for instance) that rather than displaying the text reads it aloud.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140906/70d01acb/attachment.html>
Laurie Fooks
2014-09-06 14:35:43 UTC
Permalink
Hi

The issue still stands as to what markup is common to front ends and
at what level should that apply - engine or front end.- sorry, I am
not aufait with how the sword system works at the program level

If we don't have a high level of commonality then I am concerned that
we are losing the purpose of having a common "engine"

The documentation pointed me to OSIS as the ongoing supported
standard, but sadly I am finding that is not the reality in genbooks
for anything but basics.

In some situations, it would be useful to make more use of media and
other advantages of an electronic document - sword is currently
limited and I'm not able to help with programming, but I would like to
be able to maximise use of what is available and have it usable on
whatever sword affiliated front end the end user prefers.

As I have said, I do appreciate the work many people have contributed
- I am also trying to help by giving my test results on what I have
found as a new user. I do feel that the system / project would benefit
from establishing (or publishing/clarifying same) minimum standards
for markup functionality

While I am also integrating content into other systems aimed at mobile
devices, the sword system has some benefits and I would like to be
able to use it more.

Thanks again for an excellent framework.
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
To supplement the answers already given, as far as OSIS is concerned, the
reason that <lg><l> tags are suggested to not be used for line or page
breaks is that OSIS is a semantic language meaning you are tagging what
something /is/ not how it looks. This I think is why <p> tags aren't having
the desired effect either. Unlike in HTML, <p> is specifically for
delineating paragraphs conceptually. An empty paragraph doesn't produce a
blank line like in HTML. That is a side effect of how block-level display
tags are rendered in HTML not because of something universal to <p>. As for
why you want to mark things semantically rather than presentationally,
someday there might be a front-end for visually impaired persons (for
instance) that rather than displaying the text reads it aloud.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
Karl Kleinpaste
2014-09-06 15:35:56 UTC
Permalink
Post by Laurie Fooks
If we don't have a high level of commonality then I am concerned that
we are losing the purpose of having a common "engine"
^/_This_./^

In all honesty, I have no idea what Xiphos (as the object of my personal
concern) could do differently. We use the XHTML filters, and we ask the
engine to deliver text formatted according to those filters. Nothing
more -- Xiphos is literally blind to further underlying details -- what
else is there for an application to do? Why is this not identically
what all the other applications do, or alternatively, why is the result
among them different?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140906/eed7a8a7/attachment.html>
Karl Kleinpaste
2014-09-21 15:03:36 UTC
Permalink
I find it odd that this discussion died out without any further
consideration from other app or engine developers as to why the apps'
delivery varies.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140921/5d546b6a/attachment.html>
Nic Carter
2014-09-22 02:20:02 UTC
Permalink
As a general FYI, when I would test for conformity to how text should display, I used to test PocketSword vs Xiphos vs Eloquent/MacSword vs BPBible. My testing showed that they were a reasonable source of test cases. If something looked right in them but not in PS, I knew I had a bug. :)

(Karl, I would also be interested in hearing why other front-ends don?t seem to conform. Has a lot of work gone into other front-ends to change how some modules are presented because the back-end code isn?t feature complete yet?)

(PS: I?m on holidays and half-hoping to have a new beta of PS out in the next 2 weeks. Perhaps even have a new release of PS out by Christmas? iPhone 6/6+ compatibility would be good!)
I find it odd that this discussion died out without any further consideration from other app or engine developers as to why the apps' delivery varies.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140922/1a41c838/attachment.html>
David &quot;Judah's Shadow&quot; Blue
2014-09-23 18:32:45 UTC
Permalink
Post by Laurie Fooks
Hi
The issue still stands as to what markup is common to front ends and
at what level should that apply - engine or front end.- sorry, I am
not aufait with how the sword system works at the program level
Sorry for the delayed reply, this was sitting unfinished for a good while in my drafts folder forgotten apparently.

I would say that there is some confusion as to what the sword engine does as far as getting content out from modules and in to frontends. The engine allows you, as the frontend developer, to receive the module text and tagging from the engine via various filters depending on your needs/desires. The engine reads the module, then outputs the requested passage formatted according to the filter that the frontend program has requested. For Xiphos, it requests the XHTML filter be used and then sends the resulting XHTML "document" to it's rendering code for display. For the main Windows frontend (commonly called BibleCS on this list) it requests the filter for RTF formatting codes, and then passes that to it's rendering code for display (or at least that's how it used to work). Diatheke, the command line front end, last I played with it, lets you specify the output filter to use as an argument (but defaulted to plain text with /no/ special formatting). BibleTime, on the other hand, gets the raw module tagging and transforms it into HTML itself so it can have a finer-grained control over how things are displayed via display templates (which are really just style sheets create specifically for the HTML tags BibleTime sends to render) and things like highlighting the current verse, formatting footnotes, cross references, etc. in a uniform way (determined again by the CSS), and so forth. It also changes some formatting if you request a passage be printed, so as to be more print friendly. If there isn't code to handle a particular OSIS/GBF/THML/TEI/etc. tag, poetry for instance (currently anyway), then AFAIK it gets the tags from the engine.

Now all this might sound pedantic and that front-ends should just render what the engine sends, but imagine a frontend that sends the text through a TTS engine for visually impaired persons. This frontend would have no use for HTML formatting, but it would care what the underlying markup that this HTML represents is. A TTS frontend wouldn't care that words are "red", it would care /why/ they are "red", so this front end would want the raw OSIS to be able to understand that the text is a quote from Jesus and perhaps change the voice used. Or perhaps this frontend would just want the raw text to read verbatim rather than caring what tags are present.

And then there is the case of frontends that aren't Bible reading programs at all. For instance, using graph theory to analyze word usage and compare it to the Strong's Numbers tagged in, or analyze cross references, or some other such thing.

This is why OSIS is semantic markup not presentation markup. It is also why you are discouraged from using <l> and <lg> for presentational line breaks, or to delimit prose paragraphing. It may work (for now) but what happens when a frontend comes along that does something with poetry that makes sense for poetry, but breaks your blank line? I recall someone saying that some publishers are not wanting to license their modules for use unless they can be assured the modules will display the way they want. So, a fix to a frontend for that case may break the presentation you had in mind.
Post by Laurie Fooks
If we don't have a high level of commonality then I am concerned that
we are losing the purpose of having a common "engine"
Well, no not necessarily, the purpose of the engine is to read the modules and then provide the content in a way that the front end can meaningfully use for its purpose. This can, of necessity, create /some/ disparity in how things are handled. I'll go into more detail below but each frontend knows what it needs to best display text for its purpose. The mobile phone apps, for example, may not wish to pad things with extra spacing like a laptop/desktop (or even tablet) app because of the smaller screen real estate. Or my above mentioned possible TTS frontend that just wants raw text with no formatting whatsoever.

You can look at it this way, if the engine determined how frontends should display the text, what would the point of multiple front ends be?
Post by Laurie Fooks
The documentation pointed me to OSIS as the ongoing supported
standard, but sadly I am finding that is not the reality in genbooks
for anything but basics.
Well yes, most work is for biblical texts, that's where the big efforts lie. I do believe I was around before there /were/ genbooks. So in the long history of sword they are relatively young. And not all front-ends will give them priority to endure rendering is correct. As far as BibleTime goes, IIRC, genbooks should get the same treatment as bibles, read the tags, output HTML, style according to template.
Post by Laurie Fooks
In some situations, it would be useful to make more use of media and
other advantages of an electronic document - sword is currently
limited and I'm not able to help with programming, but I would like to
be able to maximise use of what is available and have it usable on
whatever sword affiliated front end the end user prefers.
Well yes, that is the goal of the engine. Personally I'm sad that the module makers haven't been making much but exact screen reproductions of print modules and not taking advantage of the other options being digital gives. But until people need the additional features, they won't be added. Images are a good example, this is very new to the code, but wasn't put in until someone felt the need.
Post by Laurie Fooks
As I have said, I do appreciate the work many people have contributed
- I am also trying to help by giving my test results on what I have
found as a new user. I do feel that the system / project would benefit
from establishing (or publishing/clarifying same) minimum standards
for markup functionality
This is a laudable goal (with caveats for for the aforementioned cases where presentation is not visual or doesn't care about formatting for other reasons). But this is very difficult to do. BibleTime used to have code to render poetry, but it ran into problems because of the way HTML works, poetry would be fine until you selected the first verse, the the whole rest of the chapter would get highlighted like the current verse. The problem rests in how you divide up the text. We can't even get module makers to agree on this let alone frontend rendering (I'm speaking of BCV and kin not versification schemes). The one thing you have to be aware of as well is the type of module. Technically there are only 4: bible, commentary, lexicon/dictionary, and book. Any other distinction is a classification within those 4 types. So devotionals, for instance, are a special case of lexicon/dictionary modules keyed to dates. And devotional modules should be created according to lexicon guides, rather than book guides.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140923/b65ebf83/attachment.html>
Karl Kleinpaste
2014-10-08 18:33:05 UTC
Permalink
Longish ramble.

I'm still finding our lack of attention or interest regarding consistent
output somewhat disappointing. David wrote a lot a couple weeks back
about this, but some of it just plain bugs me, and no one else followed
up at all. Some of the bugs-me is non-specific, some is very specific.
Post by David &quot;Judah's Shadow&quot; Blue
Now all this might sound pedantic and that front-ends should just
render what the engine sends, but imagine a frontend that sends the
text through a TTS engine for visually impaired persons. This frontend
would have no use for HTML formatting, but it would care what the
underlying markup that this HTML represents is.
I have 2 reactions to this observation.

1. I don't know if any other frontends are capable of it, but Xiphos has
been TTS-friendly for ~8 years. (Cf. Read Aloud in the View menu for
walking straight through a Bible, or using mouse-swept regions + context
menu invocation.) And indeed, as noted, I don't care what the markup
looks like, indeed I ship the text through a tag stripper before it goes
out to Festival. There is no consideration at all to what was there, it
is all blindly removed and simply shipped for speaking. Yes, one could
hypothetically say that a change of voice could be used in the TTS case,
but -- this is important -- _nobody cares_.

You see, for as long as I've been around, there has always been a huge
amount of talk within Sword about The Wonderful Things That Could Be
Done. But the real world's bottom line is that the five-9s proportion
of our actual user base has a straightforward goal: Good, productive
Bible study using quality tools. Precious few are deaf or blind, and
almost none are interested in full-tilt syntactic analysis tools. So
all the "see, the markup could let Joe Handicap have the text delivered
in his Special Way" really doesn't mean squat in the real world.

2. I'm not arguing against OSIS. Not all, in fact. Nor against
handicap support. But what I'll say about this sort of over-attention
to the hyperactive extremes of what could be done routinely leads us to
miss, or deliberately avoid, the underlying problem.

That problem, as addressed by Laurie Fooks' experimentation, is that
collectively we do a kind of poor job of consistent rendering of what's
under there. For the five-9s crowd, what they want is good, consistent
display of textual content. For the moment, ignore the potential blind
or deaf user of our apps. The problem is that we, the frontend
developers, have a pronounced tendency to produce /different things/ for
the /same text/, as displayed in the usual panes of our apps. Is that
because of the frontend itself, or because of what the frontend gets
from the engine?

That is where Laurie's experimentation reached, and where we
collectively fall over the cliff. We are accelerating at 32f/s^2 toward
going */splat/* on the canyon floor below while blandly discussing how
nifty a more extensive TTS would be.

As far as the "not a Bible-reading program at all" crowd...I absolutely
do not care. The syntactic analyzer portion of our userbase is past the
nine-9s crowd.

It occurs to me that my "N-9s" nomenclature may be unclear or unknown.
Five-9s is 99.999%. Nine-9s is 99.9999999%. I use these in mild
hyperbole. When I say that the five-9s crowd wants just to see good
Bible textual display and whatever features can readily go with that, I
mean that out of a hundred thousand users, just one of them is outside
that usual space. Now, I said it's hyperbole, and someone will tell me
that they have a whole community of users for whom TTS is
crucial...totalling all of 10 people, or even 100 people. Well, fine,
you've moved the issue from five-9s to four-9s, 99.99%, and ...
whoopie. You have done nothing to make me feel better.

Besides, as noted, Xiphos has TTS, it's proven to be quite a bit more
welcome than I ever intended it to be -- it was my first significant
hack on then-GnomeSword, /which //I did //as an exercise /for code
familiarity's sake -- and to my knowledge there exists not one Xiphos
user who is a Xiphos user /because of /TTS. They are Xiphos users
because there are other aspects they like, having to do with workflow or
presentation or search capability or whatever else, and prefer these
aspects over other Sword apps, and TTS is a pleasantly useful side
capability they are happy to put to use.

...

The problem is that, for given OSIS constructs, the user -- and, let us
not be remiss, the publisher -- cannot be assured that what arrives at
the user's eyeballs is even readable, much less provided as intended.

Why is this? Xiphos uses straight engine output from XHTML filters.
BibleTime uses the engine but with its own filters. JSword apps have
their own entire separate engine, and JSword is now driving almost half
of all Sword apps out there. Within apps using the C++ engine, BibleCS
uses a different set of filters (RTF) which evidently do not produce the
same visual result as the XHTML filters. Consistency is lacking because
the end result of all these widely differing filtrations cannot be
counted upon. Is BibleCS' visual display different because of inherent
limitations or differences from Xiphos vis-a-vis RTF vs. HTML display
targets? I'm not in a position to render an opinion on that.

But I can say that module authors like Laurie are stuck: They are forced
to use a least common denominator set of features of OSIS, being the
preferred markup methodology, because the interpretation of that markup,
as rendered into a display window, is not consistent, cannot be counted
upon.
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
If we don't have a high level of commonality then I am concerned that
we are losing the purpose of having a common "engine"
Well, no not necessarily, the purpose of the engine is to read the
modules and then provide the content in a way that the front end can
meaningfully use for its purpose.
This makes me want to throw things.

The purpose of the engine is to produce the text according to the
filters which its client, the frontend, has chosen, and from which that
client expects consistency of output result.

That's all.

Anything else avoids the question. A frontend's "meaningful use" is
irrelevant if the engine's product is not in line with what the module
author wanted. Cf. Laurie's experience with tables and so forth. The
filters are supposed to produce output from an OSIS table spec, however
that looks in the original markup, into something that makes sense in a
frontend's HTML or RTF or WhateverElse widget. When those filters don't
do that, crud gets displayed, crud like Laurie found.
Post by David &quot;Judah's Shadow&quot; Blue
You can look at it this way, if the engine determined how frontends
should display the text, what would the point of multiple front ends be?
Wow, David, can you say "red herring"?

The reasons for picking a particular frontend have precious little to do
with that. What drives Xiphos users? Historically, for as long as I've
been involved with the code, it's been user interaction features and
visual quality, especially for user-created and -editable content, which
is why Xiphos has user annotations and editable genbooks and
tree-structured bookmarks and multi-bookmarks and verse highlights and
dynamically resizable images and a bunch of other things. That's what
users on the mailing lists have asked for, so that's what we've produced.

That the frontends should display the same text in closely the same way
should be axiomatic, and is precisely what Laurie is looking for. And
David whistled right past it. It's not textual display that
differentiates today's frontends, it's their other features far beyond
"can it display text properly?" We haven't even achieved that
level-zero axiom. We should be ashamed.

Besides this, I believe a hug/e, //HUGE/ aspect of this is bound up in
an issue that is nearly rejected outright, when it's given any attention
at all: How does The Publisher want it to look? Do we even bother to
ask? If we ask, do we listen to the answer? Laurie wants OSIS tables
to behave a certain way, namely, according to its own spec. Has anybody
taken her thoughts to heart? Have any filter fixes been done in the
name of accommodating what she perceives as bugs?
Post by David &quot;Judah's Shadow&quot; Blue
But until people need the additional features, they won't be added.
Images are a good example, this is very new to the code, but wasn't
put in until someone felt the need.
Images have been supported in the engine for as long as I've been
around, again about 8 years. This is not new by any reasonable meaning
of the word. By comparison, the XHTML filters are less than 2 years old
and are already in wide use. There has been an ImageSampler module
since long before I was around.
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
I do feel that the system / project would benefit
from establishing (or publishing/clarifying same) minimum standards
for markup functionality
This is a laudable goal (with caveats for for the aforementioned cases
where presentation is not visual or doesn't care about formatting for
other reasons). But this is very difficult to do.
You might as well have said "we can't fix bugs."

The fact that Laurie can report that Feature X (such as table display)
doesn't work consistently in OSIS markup as rendered in all the
frontends means that the engines, both C++ and JSword, are buggy.
Mothing more and nothing less. They need to be fixed so that they do
what they're expected to do, so that they behave according to spec.
There /is/ a spec, y'know, a document that says there are minimum
standards for markup functionality, just as Laurie asked immediately
above. Once that's done right, if any further frontend bugs remain in
the resulting output as displayed, then we in frontend development will
have our own bugs to fix. Until then, it's an engine problem.

--karl
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20141008/81122070/attachment-0001.html>
Troy A. Griffitts
2014-10-08 20:16:20 UTC
Permalink
Thanks for the email Karl. Yes, when I read Laurie's concise and
informative report of how we do on different features and output
formats, I was grateful in my heart and planned to use her report for
improving the XHTML filters. I agree, these are bugs and we need to fix
them. I started the XHTML filters with 2 hopes: that those who use
their own filter sets would consider collaborating together on this
filter set provided with the engine, and that those who use the XHTML
filters would improve them. We all have 5 projects we're working on
these days and as usual, what is urgent for our own work, or what is
easy and fun, is usually highest priority for each of us. I'm happy to
see a commit to improve the XHTML filters.

Regarding your TTS impl, have you considered calling
module.stripText(). This should give a reasonable plain-text
representation of a module entry.
Post by Karl Kleinpaste
Longish ramble.
I'm still finding our lack of attention or interest regarding
consistent output somewhat disappointing. David wrote a lot a couple
weeks back about this, but some of it just plain bugs me, and no one
else followed up at all. Some of the bugs-me is non-specific, some is
very specific.
Post by David &quot;Judah's Shadow&quot; Blue
Now all this might sound pedantic and that front-ends should just
render what the engine sends, but imagine a frontend that sends the
text through a TTS engine for visually impaired persons. This
frontend would have no use for HTML formatting, but it would care
what the underlying markup that this HTML represents is.
I have 2 reactions to this observation.
1. I don't know if any other frontends are capable of it, but Xiphos
has been TTS-friendly for ~8 years. (Cf. Read Aloud in the View menu
for walking straight through a Bible, or using mouse-swept regions +
context menu invocation.) And indeed, as noted, I don't care what the
markup looks like, indeed I ship the text through a tag stripper
before it goes out to Festival. There is no consideration at all to
what was there, it is all blindly removed and simply shipped for
speaking. Yes, one could hypothetically say that a change of voice
could be used in the TTS case, but -- this is important -- _nobody cares_.
You see, for as long as I've been around, there has always been a huge
amount of talk within Sword about The Wonderful Things That Could Be
Done. But the real world's bottom line is that the five-9s proportion
of our actual user base has a straightforward goal: Good, productive
Bible study using quality tools. Precious few are deaf or blind, and
almost none are interested in full-tilt syntactic analysis tools. So
all the "see, the markup could let Joe Handicap have the text
delivered in his Special Way" really doesn't mean squat in the real world.
2. I'm not arguing against OSIS. Not all, in fact. Nor against
handicap support. But what I'll say about this sort of over-attention
to the hyperactive extremes of what could be done routinely leads us
to miss, or deliberately avoid, the underlying problem.
That problem, as addressed by Laurie Fooks' experimentation, is that
collectively we do a kind of poor job of consistent rendering of
what's under there. For the five-9s crowd, what they want is good,
consistent display of textual content. For the moment, ignore the
potential blind or deaf user of our apps. The problem is that we, the
frontend developers, have a pronounced tendency to produce /different
things/ for the /same text/, as displayed in the usual panes of our
apps. Is that because of the frontend itself, or because of what the
frontend gets from the engine?
That is where Laurie's experimentation reached, and where we
collectively fall over the cliff. We are accelerating at 32f/s^2
toward going */splat/* on the canyon floor below while blandly
discussing how nifty a more extensive TTS would be.
As far as the "not a Bible-reading program at all" crowd...I
absolutely do not care. The syntactic analyzer portion of our
userbase is past the nine-9s crowd.
It occurs to me that my "N-9s" nomenclature may be unclear or
unknown. Five-9s is 99.999%. Nine-9s is 99.9999999%. I use these in
mild hyperbole. When I say that the five-9s crowd wants just to see
good Bible textual display and whatever features can readily go with
that, I mean that out of a hundred thousand users, just one of them is
outside that usual space. Now, I said it's hyperbole, and someone
will tell me that they have a whole community of users for whom TTS is
crucial...totalling all of 10 people, or even 100 people. Well, fine,
you've moved the issue from five-9s to four-9s, 99.99%, and ...
whoopie. You have done nothing to make me feel better.
Besides, as noted, Xiphos has TTS, it's proven to be quite a bit more
welcome than I ever intended it to be -- it was my first significant
hack on then-GnomeSword, /which //I did //as an exercise /for code
familiarity's sake -- and to my knowledge there exists not one Xiphos
user who is a Xiphos user /because of /TTS. They are Xiphos users
because there are other aspects they like, having to do with workflow
or presentation or search capability or whatever else, and prefer
these aspects over other Sword apps, and TTS is a pleasantly useful
side capability they are happy to put to use.
...
The problem is that, for given OSIS constructs, the user -- and, let
us not be remiss, the publisher -- cannot be assured that what arrives
at the user's eyeballs is even readable, much less provided as intended.
Why is this? Xiphos uses straight engine output from XHTML filters.
BibleTime uses the engine but with its own filters. JSword apps have
their own entire separate engine, and JSword is now driving almost
half of all Sword apps out there. Within apps using the C++ engine,
BibleCS uses a different set of filters (RTF) which evidently do not
produce the same visual result as the XHTML filters. Consistency is
lacking because the end result of all these widely differing
filtrations cannot be counted upon. Is BibleCS' visual display
different because of inherent limitations or differences from Xiphos
vis-a-vis RTF vs. HTML display targets? I'm not in a position to
render an opinion on that.
But I can say that module authors like Laurie are stuck: They are
forced to use a least common denominator set of features of OSIS,
being the preferred markup methodology, because the interpretation of
that markup, as rendered into a display window, is not consistent,
cannot be counted upon.
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
If we don't have a high level of commonality then I am concerned that
we are losing the purpose of having a common "engine"
Well, no not necessarily, the purpose of the engine is to read the
modules and then provide the content in a way that the front end can
meaningfully use for its purpose.
This makes me want to throw things.
The purpose of the engine is to produce the text according to the
filters which its client, the frontend, has chosen, and from which
that client expects consistency of output result.
That's all.
Anything else avoids the question. A frontend's "meaningful use" is
irrelevant if the engine's product is not in line with what the module
author wanted. Cf. Laurie's experience with tables and so forth. The
filters are supposed to produce output from an OSIS table spec,
however that looks in the original markup, into something that makes
sense in a frontend's HTML or RTF or WhateverElse widget. When those
filters don't do that, crud gets displayed, crud like Laurie found.
Post by David &quot;Judah's Shadow&quot; Blue
You can look at it this way, if the engine determined how frontends
should display the text, what would the point of multiple front ends be?
Wow, David, can you say "red herring"?
The reasons for picking a particular frontend have precious little to
do with that. What drives Xiphos users? Historically, for as long as
I've been involved with the code, it's been user interaction features
and visual quality, especially for user-created and -editable content,
which is why Xiphos has user annotations and editable genbooks and
tree-structured bookmarks and multi-bookmarks and verse highlights and
dynamically resizable images and a bunch of other things. That's what
users on the mailing lists have asked for, so that's what we've produced.
That the frontends should display the same text in closely the same
way should be axiomatic, and is precisely what Laurie is looking for.
And David whistled right past it. It's not textual display that
differentiates today's frontends, it's their other features far beyond
"can it display text properly?" We haven't even achieved that
level-zero axiom. We should be ashamed.
Besides this, I believe a hug/e, //HUGE/ aspect of this is bound up in
an issue that is nearly rejected outright, when it's given any
attention at all: How does The Publisher want it to look? Do we even
bother to ask? If we ask, do we listen to the answer? Laurie wants
OSIS tables to behave a certain way, namely, according to its own
spec. Has anybody taken her thoughts to heart? Have any filter fixes
been done in the name of accommodating what she perceives as bugs?
Post by David &quot;Judah's Shadow&quot; Blue
But until people need the additional features, they won't be added.
Images are a good example, this is very new to the code, but wasn't
put in until someone felt the need.
Images have been supported in the engine for as long as I've been
around, again about 8 years. This is not new by any reasonable
meaning of the word. By comparison, the XHTML filters are less than 2
years old and are already in wide use. There has been an ImageSampler
module since long before I was around.
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
I do feel that the system / project would benefit
from establishing (or publishing/clarifying same) minimum standards
for markup functionality
This is a laudable goal (with caveats for for the aforementioned
cases where presentation is not visual or doesn't care about
formatting for other reasons). But this is very difficult to do.
You might as well have said "we can't fix bugs."
The fact that Laurie can report that Feature X (such as table display)
doesn't work consistently in OSIS markup as rendered in all the
frontends means that the engines, both C++ and JSword, are buggy.
Mothing more and nothing less. They need to be fixed so that they do
what they're expected to do, so that they behave according to spec.
There /is/ a spec, y'know, a document that says there are minimum
standards for markup functionality, just as Laurie asked immediately
above. Once that's done right, if any further frontend bugs remain in
the resulting output as displayed, then we in frontend development
will have our own bugs to fix. Until then, it's an engine problem.
--karl
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20141008/ee8d5b36/attachment-0001.html>
Nic Carter
2014-10-09 04:53:45 UTC
Permalink
I agree with Karl.
I have used the standard filters & played with css to make it display properly on an iPhone screen vs iPad screen, but that hasn't changed the text itself (just padding, borders, etc, to make it easier to read on a small or medium sized screen). Also, using those same filters I have had several "blind" people email thanks for PS working flawlessly (after their bug reports!) for them with VoiceOver, so they can hear the Bible read to them & navigate properly in the app.
My only non-standard filter (I believe?) is I have a custom implementation of poetry indentation because it didn't exist in the engine until recently & I haven't tried to use the engine version of poetry html markup yet.

Forcing publishers to work with the lowest common denominator really sucks. Really really sucks.
Allowing them to work with full OSIS would be really cool. More work for us, but it'd be cool :)
Thanks for the email Karl. Yes, when I read Laurie's concise and informative report of how we do on different features and output formats, I was grateful in my heart and planned to use her report for improving the XHTML filters. I agree, these are bugs and we need to fix them. I started the XHTML filters with 2 hopes: that those who use their own filter sets would consider collaborating together on this filter set provided with the engine, and that those who use the XHTML filters would improve them. We all have 5 projects we're working on these days and as usual, what is urgent for our own work, or what is easy and fun, is usually highest priority for each of us. I'm happy to see a commit to improve the XHTML filters.
Regarding your TTS impl, have you considered calling module.stripText(). This should give a reasonable plain-text representation of a module entry.
Post by Karl Kleinpaste
Longish ramble.
I'm still finding our lack of attention or interest regarding consistent output somewhat disappointing. David wrote a lot a couple weeks back about this, but some of it just plain bugs me, and no one else followed up at all. Some of the bugs-me is non-specific, some is very specific.
Post by David &quot;Judah's Shadow&quot; Blue
Now all this might sound pedantic and that front-ends should just render what the engine sends, but imagine a frontend that sends the text through a TTS engine for visually impaired persons. This frontend would have no use for HTML formatting, but it would care what the underlying markup that this HTML represents is.
I have 2 reactions to this observation.
1. I don't know if any other frontends are capable of it, but Xiphos has been TTS-friendly for ~8 years. (Cf. Read Aloud in the View menu for walking straight through a Bible, or using mouse-swept regions + context menu invocation.) And indeed, as noted, I don't care what the markup looks like, indeed I ship the text through a tag stripper before it goes out to Festival. There is no consideration at all to what was there, it is all blindly removed and simply shipped for speaking. Yes, one could hypothetically say that a change of voice could be used in the TTS case, but -- this is important -- nobody cares.
You see, for as long as I've been around, there has always been a huge amount of talk within Sword about The Wonderful Things That Could Be Done. But the real world's bottom line is that the five-9s proportion of our actual user base has a straightforward goal: Good, productive Bible study using quality tools. Precious few are deaf or blind, and almost none are interested in full-tilt syntactic analysis tools. So all the "see, the markup could let Joe Handicap have the text delivered in his Special Way" really doesn't mean squat in the real world.
2. I'm not arguing against OSIS. Not all, in fact. Nor against handicap support. But what I'll say about this sort of over-attention to the hyperactive extremes of what could be done routinely leads us to miss, or deliberately avoid, the underlying problem.
That problem, as addressed by Laurie Fooks' experimentation, is that collectively we do a kind of poor job of consistent rendering of what's under there. For the five-9s crowd, what they want is good, consistent display of textual content. For the moment, ignore the potential blind or deaf user of our apps. The problem is that we, the frontend developers, have a pronounced tendency to produce different things for the same text, as displayed in the usual panes of our apps. Is that because of the frontend itself, or because of what the frontend gets from the engine?
That is where Laurie's experimentation reached, and where we collectively fall over the cliff. We are accelerating at 32f/s^2 toward going splat on the canyon floor below while blandly discussing how nifty a more extensive TTS would be.
As far as the "not a Bible-reading program at all" crowd...I absolutely do not care. The syntactic analyzer portion of our userbase is past the nine-9s crowd.
It occurs to me that my "N-9s" nomenclature may be unclear or unknown. Five-9s is 99.999%. Nine-9s is 99.9999999%. I use these in mild hyperbole. When I say that the five-9s crowd wants just to see good Bible textual display and whatever features can readily go with that, I mean that out of a hundred thousand users, just one of them is outside that usual space. Now, I said it's hyperbole, and someone will tell me that they have a whole community of users for whom TTS is crucial...totalling all of 10 people, or even 100 people. Well, fine, you've moved the issue from five-9s to four-9s, 99.99%, and ... whoopie. You have done nothing to make me feel better.
Besides, as noted, Xiphos has TTS, it's proven to be quite a bit more welcome than I ever intended it to be -- it was my first significant hack on then-GnomeSword, which I did as an exercise for code familiarity's sake -- and to my knowledge there exists not one Xiphos user who is a Xiphos user because of TTS. They are Xiphos users because there are other aspects they like, having to do with workflow or presentation or search capability or whatever else, and prefer these aspects over other Sword apps, and TTS is a pleasantly useful side capability they are happy to put to use.
...
The problem is that, for given OSIS constructs, the user -- and, let us not be remiss, the publisher -- cannot be assured that what arrives at the user's eyeballs is even readable, much less provided as intended.
Why is this? Xiphos uses straight engine output from XHTML filters. BibleTime uses the engine but with its own filters. JSword apps have their own entire separate engine, and JSword is now driving almost half of all Sword apps out there. Within apps using the C++ engine, BibleCS uses a different set of filters (RTF) which evidently do not produce the same visual result as the XHTML filters. Consistency is lacking because the end result of all these widely differing filtrations cannot be counted upon. Is BibleCS' visual display different because of inherent limitations or differences from Xiphos vis-a-vis RTF vs. HTML display targets? I'm not in a position to render an opinion on that.
But I can say that module authors like Laurie are stuck: They are forced to use a least common denominator set of features of OSIS, being the preferred markup methodology, because the interpretation of that markup, as rendered into a display window, is not consistent, cannot be counted upon.
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
If we don't have a high level of commonality then I am concerned that
we are losing the purpose of having a common "engine"
Well, no not necessarily, the purpose of the engine is to read the modules and then provide the content in a way that the front end can meaningfully use for its purpose.
This makes me want to throw things.
The purpose of the engine is to produce the text according to the filters which its client, the frontend, has chosen, and from which that client expects consistency of output result.
That's all.
Anything else avoids the question. A frontend's "meaningful use" is irrelevant if the engine's product is not in line with what the module author wanted. Cf. Laurie's experience with tables and so forth. The filters are supposed to produce output from an OSIS table spec, however that looks in the original markup, into something that makes sense in a frontend's HTML or RTF or WhateverElse widget. When those filters don't do that, crud gets displayed, crud like Laurie found.
Post by David &quot;Judah's Shadow&quot; Blue
You can look at it this way, if the engine determined how frontends should display the text, what would the point of multiple front ends be?
Wow, David, can you say "red herring"?
The reasons for picking a particular frontend have precious little to do with that. What drives Xiphos users? Historically, for as long as I've been involved with the code, it's been user interaction features and visual quality, especially for user-created and -editable content, which is why Xiphos has user annotations and editable genbooks and tree-structured bookmarks and multi-bookmarks and verse highlights and dynamically resizable images and a bunch of other things. That's what users on the mailing lists have asked for, so that's what we've produced.
That the frontends should display the same text in closely the same way should be axiomatic, and is precisely what Laurie is looking for. And David whistled right past it. It's not textual display that differentiates today's frontends, it's their other features far beyond "can it display text properly?" We haven't even achieved that level-zero axiom. We should be ashamed.
Besides this, I believe a huge, HUGE aspect of this is bound up in an issue that is nearly rejected outright, when it's given any attention at all: How does The Publisher want it to look? Do we even bother to ask? If we ask, do we listen to the answer? Laurie wants OSIS tables to behave a certain way, namely, according to its own spec. Has anybody taken her thoughts to heart? Have any filter fixes been done in the name of accommodating what she perceives as bugs?
Post by David &quot;Judah's Shadow&quot; Blue
But until people need the additional features, they won't be added. Images are a good example, this is very new to the code, but wasn't put in until someone felt the need.
Images have been supported in the engine for as long as I've been around, again about 8 years. This is not new by any reasonable meaning of the word. By comparison, the XHTML filters are less than 2 years old and are already in wide use. There has been an ImageSampler module since long before I was around.
Post by David &quot;Judah's Shadow&quot; Blue
Post by Laurie Fooks
I do feel that the system / project would benefit
from establishing (or publishing/clarifying same) minimum standards
for markup functionality
This is a laudable goal (with caveats for for the aforementioned cases where presentation is not visual or doesn't care about formatting for other reasons). But this is very difficult to do.
You might as well have said "we can't fix bugs."
The fact that Laurie can report that Feature X (such as table display) doesn't work consistently in OSIS markup as rendered in all the frontends means that the engines, both C++ and JSword, are buggy. Mothing more and nothing less. They need to be fixed so that they do what they're expected to do, so that they behave according to spec. There is a spec, y'know, a document that says there are minimum standards for markup functionality, just as Laurie asked immediately above. Once that's done right, if any further frontend bugs remain in the resulting output as displayed, then we in frontend development will have our own bugs to fix. Until then, it's an engine problem.
--karl
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20141009/7add216c/attachment-0001.html>
Karl Kleinpaste
2014-08-27 12:39:39 UTC
Permalink
Post by Laurie Fooks
1. Internal linking - the pattern, "MODULE:DIV1.DIV2.DIV3" in the
Crosswire wiki does not work in any front end -
"MODULE:DIV1/DIV2/DIV3" works in Xiphos and BPBible and
"MODULE://DIV1/DIV2/DIV3" is needed for BibleTime and BibleTime-Mini.
Is there a "correct" OSIS markup, or does it depend on the front end?
Caveat: I don't "do" OSIS, but I am the guy mostly in charge of Xiphos.

Xiphos fairly blindly takes whatever came out of the engine and drops it
into the subwindow pane to show the text. Whatever linkage came out of
the engine is what Xiphos gives to the user. BibleTime has somewhat
different OSIS->HTML filters; it is possible that its result for
conversion to use in its HTML widgets is not the same. This might be a
BT bug.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
The only constraint for successful display in Xiphos is that the images
are placed in proper relative position in the directory structure. By
convention this uses a subdirectory "images" in which the files are
contained, and they are referenced from the text as src="/images/xyz.jpg".
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140827/e4ddb16d/attachment.html>
Laurie Fooks
2014-08-27 22:04:11 UTC
Permalink
Thanks Karl,

Xiphos is displaying most of the OSIS markup - with exceptions seen in
my test module:

- line indents using <l level="2">
- some <hi> formats
- tables

again, it may be an incorrect OSIS markup or conf file in my module

Cheers
Laurie
Post by Karl Kleinpaste
Post by Laurie Fooks
1. Internal linking - the pattern, "MODULE:DIV1.DIV2.DIV3" in the
Crosswire wiki does not work in any front end -
"MODULE:DIV1/DIV2/DIV3" works in Xiphos and BPBible and
"MODULE://DIV1/DIV2/DIV3" is needed for BibleTime and BibleTime-Mini.
Is there a "correct" OSIS markup, or does it depend on the front end?
Caveat: I don't "do" OSIS, but I am the guy mostly in charge of Xiphos.
Xiphos fairly blindly takes whatever came out of the engine and drops it
into the subwindow pane to show the text. Whatever linkage came out of
the engine is what Xiphos gives to the user. BibleTime has somewhat
different OSIS->HTML filters; it is possible that its result for
conversion to use in its HTML widgets is not the same. This might be a
BT bug.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
The only constraint for successful display in Xiphos is that the images
are placed in proper relative position in the directory structure. By
convention this uses a subdirectory "images" in which the files are
contained, and they are referenced from the text as src="/images/xyz.jpg".
Karl Kleinpaste
2014-08-27 23:07:11 UTC
Permalink
Post by Laurie Fooks
Xiphos is displaying most of the OSIS markup - with exceptions seen in
- line indents using <l level="2">
- some <hi> formats
- tables
I have heard now and again that tables don't survive OSIS->anything
filtering very well. I know that Xiphos itself can deal with tables
just fine, /if/ the content can get as far as Xiphos to begin with:
Xiphos generates tables internally (commentary by chapter is done with a
table, using verse# in left column, text in right).

Highlight is entirely a matter of Sword's filters.

Line indents... Don't know a thing about it. I can only resort to the
usual "whatever the filters provide, Xiphos displays" perspective.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140827/e8e1196a/attachment.html>
Laurie Fooks
2014-08-27 23:46:36 UTC
Permalink
Thanks Karl,

Both BibleTime and Xulsword display the table as in my test module.
The markup for tables was copy / paste from the Crosswire wiki OSIS
page.

Line indents are important for poetry markup .. I'll have to delve
again into how this is done in OSIS bibles... but last time I checked,
it was not helpful.

Generally speaking, maybe this general OSIS situation has not been so
apparent as I have not been able to find genbook modules using
extensive OSIS markup.

I am not a programmer, but will look at the filters to see what I can
discover, though as all the markup in my test module displays in one
or more front ends ... its strange!

Cheers

Laurie
Post by Karl Kleinpaste
Post by Laurie Fooks
Xiphos is displaying most of the OSIS markup - with exceptions seen in
- line indents using <l level="2">
- some <hi> formats
- tables
I have heard now and again that tables don't survive OSIS->anything
filtering very well. I know that Xiphos itself can deal with tables
Xiphos generates tables internally (commentary by chapter is done with a
table, using verse# in left column, text in right).
Highlight is entirely a matter of Sword's filters.
Line indents... Don't know a thing about it. I can only resort to the
usual "whatever the filters provide, Xiphos displays" perspective.
refdoc at gmx.net ()
2014-08-28 06:17:41 UTC
Permalink
There is a module maintainer mode deeply buried in pocketsword's settings which allows you to upload a zipped module onto your phone. It is created exactly for your scenario

----- Reply message -----
From: "Laurie Fooks" <laurie.fooks at gmail.com>
To: "SWORD Developers' Collaboration Forum" <sword-devel at crosswire.org>
Subject: [sword-devel] OSIS markup for gen books and devotionals
Date: Thu, Aug 28, 2014 07:05


Hi Nic

I just has a look at Psalms on PocketSword in a bible version using
<lg><l> markup -its great as it does display the <l level="2"> etc
tags to give the indenting. I don't see anything else unexpected ?
Did I miss something ... Is line spacing the same... it was hard to
tell? I would love to try my test mods on the PocketSword.

Cheers

Laurie
Post by Nic Carter
Hi Laurie,
Some front-ends will apply some special formatting for poetry & you don't
want that formatting for your modules, so don't mark it as poetry & you'll
be fine :)
(PocketSword is an example, if you wanted to test on an iOS device.)
Thanks, ybic
Nic. :)
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
Really appreciate if you can also look at the <figure> tag - BibleTime
/ BT-Mini show an indicator that there is an image, but is not
displaying the image. BibleTime does display images in ThML formatted
modules.
Cheers
Laurie
On August 26, 2014 7:44:58 PM EDT, Laurie Fooks <laurie.fooks at gmail.com>
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am
working
on formatting poetry "correctly" in BibleTime (i.e. indenting, block
formatting, etc). So using lg or l for merely the line breaks is a bad
idea.
Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test
module in it. I don't recall though, if that was a commentary or a
genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140828/0d084d7b/attachment-0001.html>
Nic Carter
2014-08-28 06:20:46 UTC
Permalink
(Except GenBook format is still sadly unsupported...)
Post by refdoc at gmx.net ()
There is a module maintainer mode deeply buried in pocketsword's settings which allows you to upload a zipped module onto your phone. It is created exactly for your scenario
----- Reply message -----
From: "Laurie Fooks" <laurie.fooks at gmail.com>
To: "SWORD Developers' Collaboration Forum" <sword-devel at crosswire.org>
Subject: [sword-devel] OSIS markup for gen books and devotionals
Date: Thu, Aug 28, 2014 07:05
Hi Nic
I just has a look at Psalms on PocketSword in a bible version using
<lg><l> markup -its great as it does display the <l level="2"> etc
tags to give the indenting. I don't see anything else unexpected ?
Did I miss something ... Is line spacing the same... it was hard to
tell? I would love to try my test mods on the PocketSword.
Cheers
Laurie
Post by Nic Carter
Hi Laurie,
Some front-ends will apply some special formatting for poetry & you don't
want that formatting for your modules, so don't mark it as poetry & you'll
be fine :)
(PocketSword is an example, if you wanted to test on an iOS device.)
Thanks, ybic
Nic. :)
Post by Laurie Fooks
Thanks David,
Please look at my second set of OSIS genbook test modules - I may be
formatting incorrectly. This second set includes <p> tags but
BibleTime is not displaying these as intended.
The OSIS site also suggests that <lg> <l> not be used for pagebreaks -
I am not sure why it is not a good idea? - as it stands, it is the
only markup that I have found to work across all front ends.
Really appreciate if you can also look at the <figure> tag - BibleTime
/ BT-Mini show an indicator that there is an image, but is not
displaying the image. BibleTime does display images in ThML formatted
modules.
Cheers
Laurie
On August 26, 2014 7:44:58 PM EDT, Laurie Fooks <laurie.fooks at gmail.com>
Post by Laurie Fooks
2. Paragraphs and linebreaks - I have found the poetry markup (lg, l)
is the only reliable way to have line breaks / paragraphs - Its
working well, but is there an alternate I should use?
I can't speak for other front-ends and poetry formatting, but I am
working
on formatting poetry "correctly" in BibleTime (i.e. indenting, block
formatting, etc). So using lg or l for merely the line breaks is a bad
idea.
Plus, as Peter said, it should be working for the other methods.
Post by Laurie Fooks
3. Images are not displayed, except in Xiphos, xulsword and AndBible.
- Is this a front end design choice or bug?
BibleTime will display pictures I know, I've played with the images test
module in it. I don't recall though, if that was a commentary or a
genbook.
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140828/b3c04ca3/attachment.html>
refdoc at gmx.net ()
2014-08-28 16:42:26 UTC
Permalink
To qualify Karl's response, I think the OSIS genbook support is less solid than THML.

----- Reply message -----
From: "Karl Kleinpaste" <karl at kleinpaste.org>
To: "SWORD Developers&apos; Collaboration Forum" <sword-devel at crosswire.org>
Subject: [sword-devel] OSIS markup for gen books and devotionals
Date: Thu, Aug 28, 2014 16:42
On 08/28/2014 11:10 AM, Laurie Fooks
wrote:



Is it possible that part of the prob may be that most genbooks have
historically used "ThML" and some front ends are geared towards that
markup?

$ cd ~/.sword/mods.d

$ grep -l ^DataPath.*genbook * | xargs grep ^SourceType | tr -d
'\r' | cut -f2 -d= | tr A-Z a-z | sort | uniq -c | sort

1 plain

1 plaintext

1 tei

29 osis

57 thml



Certainly there is a lot of ThML, but genbooks are no stranger to
OSIS.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140828/67d7b8ac/attachment.html>
refdoc at gmx.net ()
2014-09-22 05:40:34 UTC
Permalink
I would guess the main differences in output are all accounted for by checking which combination of rendering engine and filter set is employed. BT e.g. wraps and reimplements the sword engine's filters. BD and And Bible use jsword, but use different exit points afaik, former chases all module content through a XSLT conversion to create HTML, latter does something else.


----- Reply message -----
From: "Nic Carter" <niccarter at mac.com>
To: "SWORD Developers&apos; Collaboration Forum" <sword-devel at crosswire.org>
Subject: [sword-devel] OSIS markup for gen books and devotionals
Date: Mon, Sep 22, 2014 03:20
As a general FYI, when I would test for conformity to how text should display, I used to test PocketSword vs Xiphos vs Eloquent/MacSword vs BPBible. My testing showed that they were a reasonable source of test cases. If something looked right in them but not in PS, I knew I had a bug. :)(Karl, I would also be interested in hearing why other front-ends don?t seem to conform. Has a lot of work gone into other front-ends to change how some modules are presented because the back-end code isn?t feature complete yet?)(PS: I?m on holidays and half-hoping to have a new beta of PS out in the next 2 weeks. Perhaps even have a new release of PS out by Christmas? iPhone 6/6+ compatibility would be good!)
On 22 Sep 2014, at 1:03 am, Karl Kleinpaste <karl at kleinpaste.org> wrote:




I find it odd that this discussion died out
without any further consideration from other app or engine developers
as to why the apps' delivery varies.


_______________________________________________sword-devel mailing list: sword-devel at crosswire.orghttp://www.crosswire.org/mailman/listinfo/sword-develInstructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140922/e7894eb5/attachment.html>
DM Smith
2014-09-22 14:41:28 UTC
Permalink
WRT to JSword, we only have one OSIS/TEI filter which transforms to HTML (actually, this is an XSLT script). Our other filters (PlainText, GBF, ThML) transforms to OSIS and then runs through the OSIS -> HTML filter. The same filter is used by all JSword frontends with small variations.

The current release of JSword and the next release of JSword differ. Some frontends (STEP, AndBible) are at the next release level. Notably BibleDesktop is not, but should have been. Don't know about Alkitab. This would account for some variation in JSword.

We currently don't handle intra-document linking except for images as relative urls where the base is the root of the module.

On another note: osis2mod does not require OSIS (except that which is needed to split the module into verses) or verify OSIS. It assumes that input has been validated externally. It is quite possible for HTML (e.g. <br/>, <span font="red">...</span>) to be in the input and it would be stored in the module as such. How different engines and frontends deal with that is highly variable. I think JSword will emit a warning and strip the elements and their attributes, not their content, in the XSL.

Another place of difference is the handling of vertical whitespace. In HTML nesting of block elements doesn't produce extra whitespace when adjacent opening or closing tags are present. This is not handled properly by the filters, which needs to simulate it. OSIS has the notion of milestone starts and ends of these elements. This does not directly translate into HTML. Also, the preverse div (opening and closing elements) needs to never produce vertical whitespace. There already have been lots of threads on this.

In Him,
DM Smith
Post by refdoc at gmx.net ()
I would guess the main differences in output are all accounted for by checking which combination of rendering engine and filter set is employed. BT e.g. wraps and reimplements the sword engine's filters. BD and And Bible use jsword, but use different exit points afaik, former chases all module content through a XSLT conversion to create HTML, latter does something else.
----- Reply message -----
From: "Nic Carter" <niccarter at mac.com>
To: "SWORD Developers' Collaboration Forum" <sword-devel at crosswire.org>
Subject: [sword-devel] OSIS markup for gen books and devotionals
Date: Mon, Sep 22, 2014 03:20
As a general FYI, when I would test for conformity to how text should display, I used to test PocketSword vs Xiphos vs Eloquent/MacSword vs BPBible. My testing showed that they were a reasonable source of test cases. If something looked right in them but not in PS, I knew I had a bug. :)
(Karl, I would also be interested in hearing why other front-ends don?t seem to conform. Has a lot of work gone into other front-ends to change how some modules are presented because the back-end code isn?t feature complete yet?)
(PS: I?m on holidays and half-hoping to have a new beta of PS out in the next 2 weeks. Perhaps even have a new release of PS out by Christmas? iPhone 6/6+ compatibility would be good!)
I find it odd that this discussion died out without any further consideration from other app or engine developers as to why the apps' delivery varies.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140922/cf1c38e8/attachment.html>
Jon Behrens
2014-09-22 20:28:06 UTC
Permalink
I've finally gotten the C# binding examples to run both on Linux and
Windows. This means,
of course, that one should be able to write C# code on either platform
and have the resulting
application also run on either. (At least at this point the C# examples
packaged with the Sword
distribution run on both platforms using identical C# code.)

I've written a tutorial outlining the steps needed to accomplish this.
That's attached as a
text file. Would it be appropriate to add this to the developer's wiki?

Be blessed,
Jon

-------------- next part --------------
Making Sword C# Bindings for windows

1. Set up Sword for windows according to these instructions:
http://crosswire.org/wiki/Tutorial:Compiling_%26_Installing_SWORD_on_Windows

Except, stop before making libsword.sln, you will need to make some changes before
the project will build successfully.

2. Open \sword\sword\lib\vcppmake\libsword.sln in VS2013 and allow the project to
be converted.

3. Open the project properties window

3.1 Under the C/C++ tab General, edit additional include directories
Change icu-sword to icu

3.2 Under the Linker tab General, edit additional library directories
Change libcurl-vc10-x86-release-static-ipv6-sspi-spnego-winssl/lib to
libcurl-vc-x86-release-static-ipv6-sspi-spnego-winssl/lib

Change icu-sword/lib to icu/lib

4. In the Solution Explorer window, drag the file: sword\bindings\flatapi.cpp
into the solution.

5. Open flatapi.h

5.1 Replace all ' * SWDLLEXPORT ' with ' SWDLLEXPORT * ' (without the quotes)

5.2 Replace all ' ** SWDLLEXPORT ' with ' SWDLLEXPORT ** ' (without the quotes)

5.3 Declare the following function:

SWHANDLE SWDLLEXPORT org_crosswire_sword_SWMgr_newWithPath(const char *thePath);


6. Open flatapi.cpp

6.1 Make the replacements as in step 5

6.2 Change all ::clearModInfo to clearTheModInfo (remove the colons and rename)

6.3 Change the declaration of clearModInfo in the unnamed namespace to clearTheModInfo

6.4 Define the function in 5.3 above:

SWHANDLE SWDLLEXPORT org_crosswire_sword_SWMgr_newWithPath(const char *thePath) {
SWConfig *sysConf = new SWConfig(thePath);
return (SWHANDLE) new HandleSWMgr(new WebMgr(sysConf));
}

7. At this point, libsword.sln should make without errors - either release or debug.

8. In the Sword distribution, there is a bindings directory having a csharp directory.
In that directory, edit the file NativeMethods.cs:

8.1 In the NativeMethods class the DLLNAME changes from libsword.so to libsword.dll

8.2 In the NativeMethods class change:
[DllImport(DLLNAME)] to
[DllImport(DLLNAME, CallingConvention=CallingConvention.Cdecl)]

9. Put all of the dlls in the sword project where C# can find them. Quick and dirty is to
copy them all to the bin directory for the executable you will build. You may need the
following dlls (I don't know yet which dlls do what, so I've included them all from the
Windows build of the Sword distribution. This list works, a lesser list may be sufficient.):

icule53.dll clucene-core.dll icudt53.dll icuuc53.dll
liblzma.dll icuio53.dll icuin53.dll binding.dll
icutu53.dll iculx53.dll clucene-shared.dll
libsword.dll libbz2.dll

10. Figure out where you want your data files and edit sword.conf to point to that
directory. Also put sword.conf somewhere reasonable.

11. In sword\bindings\csharp\examples edit LookupExample.cs
using (var manager = new manager()) //changes to
using (var manager = new manager(@"path to sword.conf"))
Greg Hellings
2014-09-22 20:36:12 UTC
Permalink
Jon,

It most definitely would be wiki material. Are there any code changes you
needed to make? Patch files? If so, you can submit those as well for
inclusion. A few comments about the steps you're following:

Changing out icu-sword for icu and the change to libcurl shouldn't be
necessary. If you followed the directions in the wiki you should have built
icu-sword from the Sword repository instead of the pre-distributed version
of ICU from upstream. The change to libcurl appears to be specific to your
version of Visual Studio. I've noticed that some versions don't include
vcXX as well.

The other changes might be ones which should be incorporated into the
codebase. Troy would need to comment more about the changes you're
proposing to flatapi.cpp/h.

Glad to hear you've gotten it working now!

--Greg
Post by Jon Behrens
I've finally gotten the C# binding examples to run both on Linux and
Windows. This means,
of course, that one should be able to write C# code on either platform and
have the resulting
application also run on either. (At least at this point the C# examples
packaged with the Sword
distribution run on both platforms using identical C# code.)
I've written a tutorial outlining the steps needed to accomplish this.
That's attached as a
text file. Would it be appropriate to add this to the developer's wiki?
Be blessed,
Jon
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140922/ebd4ae29/attachment.html>
Jon Behrens
2014-09-22 21:29:31 UTC
Permalink
Thank you Greg.

As to icu-sword, the instructions on the wiki say to download it from
site.icu-project.org. If there's
a Sword specific version, perhaps the wiki could be updated to point
there? Or if you can give me
the URL, I'll include it in my write up.

As to libcurl, I'm using VS2013 which apparently doesn't include the
compiler version in the library
name. In any case, the note to check the actual name of the library in
the linker should probably
stay.

The syntax changes to the flatapi are driven by differences in MS C++
syntax. They're specific to
Windows and probably are of no general interest to the broader Linux
community.

In his NativeMethods class, Troy has a call to
org_crosswire_sword_SWMgr_newWithPath, but
that function is not declared or defined in flatapi. I just went ahead
and implemented it. Whether
that should be a permanent change is, of course, his call.

I did rewicker the C# project so its layout made a bit more sense to me
and so that it might be
easier for cross platform development. If anyone is interested, I would
be happy to include those
project files.

Finally, how would I go about submitting an entry to the wiki?

Jon
Post by Greg Hellings
Jon,
It most definitely would be wiki material. Are there any code changes
you needed to make? Patch files? If so, you can submit those as well
Changing out icu-sword for icu and the change to libcurl shouldn't be
necessary. If you followed the directions in the wiki you should have
built icu-sword from the Sword repository instead of the
pre-distributed version of ICU from upstream. The change to libcurl
appears to be specific to your version of Visual Studio. I've noticed
that some versions don't include vcXX as well.
The other changes might be ones which should be incorporated into the
codebase. Troy would need to comment more about the changes you're
proposing to flatapi.cpp/h.
Glad to hear you've gotten it working now!
--Greg
On Mon, Sep 22, 2014 at 3:28 PM, Jon Behrens <jbb at crimsonthread.com
I've finally gotten the C# binding examples to run both on Linux
and Windows. This means,
of course, that one should be able to write C# code on either
platform and have the resulting
application also run on either. (At least at this point the C#
examples packaged with the Sword
distribution run on both platforms using identical C# code.)
I've written a tutorial outlining the steps needed to accomplish
this. That's attached as a
text file. Would it be appropriate to add this to the developer's wiki?
Be blessed,
Jon
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
<mailto:sword-devel at crosswire.org>
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20140922/0d65247a/attachment.html>
David Haslam
2014-09-23 08:10:58 UTC
Permalink
Wiki editing....

New user account requests are now moderated.
Anyone who has been a member for at least 4 days can edit a wiki once they
have logged in.

See foot of http://crosswire.org/wiki/Main_Page

David Haslam



--
View this message in context: http://sword-dev.350566.n4.nabble.com/OSIS-markup-for-gen-books-and-devotionals-tp4654106p4654187.html
Sent from the SWORD Dev mailing list archive at Nabble.com.
Daniel Hughes
2014-09-23 11:30:46 UTC
Permalink
The changes you needed to make the c# bindings themselves need to make
it back into the codebase.

I'll submit a patch for CallingConvention = CallingConvention.Cdecl,
this should be set on all the native method calls, not sure why it
wasn't

I would like to see your project files, regarding the nunit
references. As per my previous email.

I believe the org_crosswire_sword_SWMgr_newWithPath change already
exists on the trunk but didn't make it onto the release branch.

I can't comment on changes to the flat api (not a c++ expert) except
to say that we should be aiming to make it build on linux and windows
without needing any code changes.

God bless,
Daniel Hughes
Post by David Haslam
Wiki editing....
New user account requests are now moderated.
Anyone who has been a member for at least 4 days can edit a wiki once they
have logged in.
See foot of http://crosswire.org/wiki/Main_Page
David Haslam
--
View this message in context: http://sword-dev.350566.n4.nabble.com/OSIS-markup-for-gen-books-and-devotionals-tp4654106p4654187.html
Sent from the SWORD Dev mailing list archive at Nabble.com.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Jon Behrens
2014-09-23 19:35:04 UTC
Permalink
Hi Daniel

It looks like moving the SWDLLEXPORT macro to the other side of the * or **
also works in Linux. The MS C++ compiler throws a syntax error for *
SWDLLEXPORT
but works fine for SWDLLEXPORT *. The Gnu compiler on Linux takes either
one. I've
not looked at the language spec to see who's right.

Similarly, MS C++ throws when trying to call ::clearModInfo. It regards
:: as specifying
the global namespace. Simply renaming the function to clearTheModInfo
removes the
name conflict with the class method and solves that problem.

In addition to adding

SWHANDLE SWDLLEXPORT org_crosswire_sword_SWMgr_newWithPath(const char*)

I've also had to program:

void SWDLLEXPORT org_crosswire_sword_InstallMgr_delete(SWHANDLE
hInstallMgr)

without it, the unit tests of the InstallMgr all die.

I'm still working through the unit tests. InstallMgr now works, the
other two still have
some problems.

So, pending any other changes I need to make in flatapi, the same C++
code seems to
work on both Windows and Linux. Obviously, the C# code does also.

I've applied for membership in the wiki (didn't realize that that is
separate from this
list). Once that comes through and I'm clear to post, I'll add the final
write up.

Be blessed,
Jon
Post by Daniel Hughes
The changes you needed to make the c# bindings themselves need to make
it back into the codebase.
I'll submit a patch for CallingConvention = CallingConvention.Cdecl,
this should be set on all the native method calls, not sure why it
wasn't
I would like to see your project files, regarding the nunit
references. As per my previous email.
I believe the org_crosswire_sword_SWMgr_newWithPath change already
exists on the trunk but didn't make it onto the release branch.
I can't comment on changes to the flat api (not a c++ expert) except
to say that we should be aiming to make it build on linux and windows
without needing any code changes.
God bless,
Daniel Hughes
Post by David Haslam
Wiki editing....
New user account requests are now moderated.
Anyone who has been a member for at least 4 days can edit a wiki once they
have logged in.
See foot of http://crosswire.org/wiki/Main_Page
David Haslam
--
View this message in context: http://sword-dev.350566.n4.nabble.com/OSIS-markup-for-gen-books-and-devotionals-tp4654106p4654187.html
Sent from the SWORD Dev mailing list archive at Nabble.com.
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Jon Behrens
2014-09-25 23:32:54 UTC
Permalink
Success.

I've now got the C# bindings so they run without error on both Windows
and Linux
using the same source code. This includes the LookupExample and all of
the unit tests.

The project files differ between the two OSs because of differences
between MonoDevelop
and VS2013, but symbolic links on a network drive allows either OS to
work on the
same sources.

I have put in a bug report for the Sword C++ project - it behaves
differently in Windows
and Linux depending on whether a path to sword.conf is passed as an
argument or the
default search function is used to find it. Because of that problem in
Windows, I wrote
a class to handle parsing the sword.conf file and just pass actual paths
to the Sword
C++ functions. I think I've made reasonable choices in that class, but
freely admit that
I'm really new to Sword and will humbly accept correction. I've taken
the liberty of placing
the Sword Project disclaimer on the new class I wrote - If that's not
proper, I'll remove it.

I would be happy to post the tutorial I wrote on getting everything to
run in Windows
to the Wiki if the administrator would accept me. I put in a request a
few days ago and
have heard nothing back. My developer password doesn't work.

I've uploaded the MonoDev project file to
http://midrash.crimsonthread.com/. The file
name is cSharpSword.zip. Just click to download. If it is useful, feel
free to post it or take
any of its ideas or code.

Finally, as I start actual development, are there any C# projects extant
that I might either
contribute to or get some ideas from?

Be blessed,
Jon
Jon Behrens
2014-09-26 00:46:59 UTC
Permalink
One other thing...The Sword module functions that work via cUrl don't
function over
a VPN...at least on Windows, haven't tried it on Linux.
Post by Jon Behrens
Success.
I've now got the C# bindings so they run without error on both Windows
and Linux
using the same source code. This includes the LookupExample and all of
the unit tests.
The project files differ between the two OSs because of differences
between MonoDevelop
and VS2013, but symbolic links on a network drive allows either OS to
work on the
same sources.
I have put in a bug report for the Sword C++ project - it behaves
differently in Windows
and Linux depending on whether a path to sword.conf is passed as an
argument or the
default search function is used to find it. Because of that problem in
a class to handle parsing the sword.conf file and just pass actual
paths to the Sword
C++ functions. I think I've made reasonable choices in that class, but
freely admit that
I'm really new to Sword and will humbly accept correction. I've taken
the liberty of placing
the Sword Project disclaimer on the new class I wrote - If that's not
proper, I'll remove it.
I would be happy to post the tutorial I wrote on getting everything to
run in Windows
to the Wiki if the administrator would accept me. I put in a request a
few days ago and
have heard nothing back. My developer password doesn't work.
I've uploaded the MonoDev project file to
http://midrash.crimsonthread.com/. The file
name is cSharpSword.zip. Just click to download. If it is useful, feel
free to post it or take
any of its ideas or code.
Finally, as I start actual development, are there any C# projects
extant that I might either
contribute to or get some ideas from?
Be blessed,
Jon
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
Jon Behrens
2014-10-02 18:11:33 UTC
Permalink
I've set up the Wiki entry for the C# Windows Bindings tutorial here:

http://crosswire.org/wiki/CSharp_Bindings_on_Windows

I've not made any links to the page because I'm not sure whether it is
of general
interest or not. The search function should find it OK and I'll be happy
to put a link
to it somewhere if that would be appropriate.

Thanks again to everyone who helped me to figure this out.

Be blessed,
Jon
David Haslam
2014-09-26 08:45:27 UTC
Permalink
Hi Jon,

I just accepted your request to join the developers' wiki.

David Haslam



--
View this message in context: http://sword-dev.350566.n4.nabble.com/OSIS-markup-for-gen-books-and-devotionals-tp4654106p4654202.html
Sent from the SWORD Dev mailing list archive at Nabble.com.
Refdoc
2014-10-02 19:49:18 UTC
Permalink
It is a recurring query. So, please do link in all places which seem appropriate. It is a wiki after all. Someone will fix it if they think you made a mess.

Peter
Post by Jon Behrens
http://crosswire.org/wiki/CSharp_Bindings_on_Windows
I've not made any links to the page because I'm not sure whether it is
of general
interest or not. The search function should find it OK and I'll be happy
to put a link
to it somewhere if that would be appropriate.
Thanks again to everyone who helped me to figure this out.
Be blessed,
Jon
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
David Haslam
2014-10-03 12:56:10 UTC
Permalink
Just added a couple of links and a category, etc.

David



--
View this message in context: http://sword-dev.350566.n4.nabble.com/OSIS-markup-for-gen-books-and-devotionals-tp4654106p4654206.html
Sent from the SWORD Dev mailing list archive at Nabble.com.
Jon Behrens
2014-10-07 19:56:21 UTC
Permalink
Hello again,

There are some breaking differences between the Windows version of
'libsword'
and the Linux version. When executing the same C# code I get different
results
depending on which OS I am running. Here is the code I'm running (the
two OSs
use the same file with symbolic links, so they are identical.)

public static void testBench(string modName, string outfile) {
StreamWriter sw = new StreamWriter(outfile, false, Encoding.Unicode);
using (var manager = new Manager(Enviro.swordHome)) {
var module = manager.GetModuleByName(modName);
if (module == null) {
sw.WriteLine("******Error*******");
sw.WriteLine("Could not find {0}.", modName);
}
module.KeyText = "gen.1.3";
while (!module.PopError()) {
sw.WriteLine(module.KeyText);
sw.WriteLine(module.RenderText());
sw.WriteLine("RawEntry length = " + module.RawEntry.Length);
sw.WriteLine("EntrySize = " + module.EntrySize);
module.Prevous();
}
}
sw.Close();
}

*********Linux Version ************
Genesis 1:3
And God said, ?Let there be light,? and there was light.
RawEntry length = 358
EntrySize = 362

Genesis 1:2
The earth was without form and void, and darkness was over the face of
the deep. And the Spirit of God was hovering over the face of the
waters. <br />
<br />
RawEntry length = 348
EntrySize = 348

Genesis 1:1
In the beginning, God created the heavens and the earth.
RawEntry length = 879
EntrySize = 879

************Windows Version*****************
Genesis 1:3
And God said, ???Let there be light,??? and there was light.
RawEntry length = 362
EntrySize = 7513747286636101994

Genesis 1:2
The earth was without form and void, and darkness was over the face of
the deep. And the Spirit of God was hovering over the face of the
waters. <br />
<br />
RawEntry length = 348
EntrySize = 7513747286636101980

Genesis 1:1
In the beginning, God created the heavens and the earth.
RawEntry length = 879
EntrySize = 7513747286636102511
**********************************************

Notice in the Linux version the quotes in Gen.1.3 around "Let there be
light," render
properly and those in Windows do not.

The underlying function in flatapi.cpp is:
const char SWDLLEXPORT * org_crosswire_sword_SWModule_renderText
(SWHANDLE hSWModule)

Notice that the two entry lengths give different numbers in Linux than
Windows. (In neither
case do the numbers appear to mean anything with Windows having the
advantage of not even
looking reasonable.)

At first blush, it looks as if there is a compiler option not properly
set in Windows so that unicode
module text is being processed as ASCII which is then being passed to C#.

Thanks for any help - and blessings,
Jon
Jon Behrens
2014-10-08 14:55:38 UTC
Permalink
<red faced/> Font.
Post by Jon Behrens
Hello again,
There are some breaking differences between the Windows version of
'libsword'
and the Linux version. When executing the same C# code I get different
results
depending on which OS I am running. Here is the code I'm running (the
two OSs
use the same file with symbolic links, so they are identical.)
public static void testBench(string modName, string outfile) {
StreamWriter sw = new StreamWriter(outfile, false, Encoding.Unicode);
using (var manager = new Manager(Enviro.swordHome)) {
var module = manager.GetModuleByName(modName);
if (module == null) {
sw.WriteLine("******Error*******");
sw.WriteLine("Could not find {0}.", modName);
}
module.KeyText = "gen.1.3";
while (!module.PopError()) {
sw.WriteLine(module.KeyText);
sw.WriteLine(module.RenderText());
sw.WriteLine("RawEntry length = " + module.RawEntry.Length);
sw.WriteLine("EntrySize = " + module.EntrySize);
module.Prevous();
}
}
sw.Close();
}
*********Linux Version ************
Genesis 1:3
And God said, "Let there be light," and there was light.
RawEntry length = 358
EntrySize = 362
Genesis 1:2
The earth was without form and void, and darkness was over the face of
the deep. And the Spirit of God was hovering over the face of the
waters. <br />
<br />
RawEntry length = 348
EntrySize = 348
Genesis 1:1
In the beginning, God created the heavens and the earth.
RawEntry length = 879
EntrySize = 879
************Windows Version*****************
Genesis 1:3
And God said, ?EURoeLet there be light,?EUR? and there was light.
RawEntry length = 362
EntrySize = 7513747286636101994
Genesis 1:2
The earth was without form and void, and darkness was over the face of
the deep. And the Spirit of God was hovering over the face of the
waters. <br />
<br />
RawEntry length = 348
EntrySize = 7513747286636101980
Genesis 1:1
In the beginning, God created the heavens and the earth.
RawEntry length = 879
EntrySize = 7513747286636102511
**********************************************
Notice in the Linux version the quotes in Gen.1.3 around "Let there be
light," render
properly and those in Windows do not.
const char SWDLLEXPORT * org_crosswire_sword_SWModule_renderText
(SWHANDLE hSWModule)
Notice that the two entry lengths give different numbers in Linux than
Windows. (In neither
case do the numbers appear to mean anything with Windows having the
advantage of not even
looking reasonable.)
At first blush, it looks as if there is a compiler option not properly
set in Windows so that unicode
module text is being processed as ASCII which is then being passed to C#.
Thanks for any help - and blessings,
Jon
_______________________________________________
sword-devel mailing list: sword-devel at crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20141008/21778913/attachment.html>
Loading...