Difference between revisions of "Whiteboard/Virtual Modules"
|Line 51:||Line 51:|
Revision as of 13:49, 11 January 2018
There once was some consensus that a thing called virtual modules should exist and be implemented in the API. We can whiteboard the idea/implementation here.
The sword-devel discussion from January 2006 exists here.
Front ends should be free to use or ignore virtual modules according to their design preference. We should probably have them default to on(?) but be easy to deactivate. The reason to default to on is simply that it will be self-evident that the feature exists if enable by default, whereas it might go unnoticed by new developers if defaulted to off.
Suggested Virtual Modules
This is the only virtual module that was ever actually implemented, compiled, and briefly tested. Unfortunately, Osk, sometime after implementing it, deleted or lost the implementation without having committed it. So--it will need to be re-done.
It should be fairly straightforward to implement again, via EntryAttributes.
BibleCS currently has a "PARALLEL" module. The idea here is to push the parallel module functionality back into the API. The module should contain the text of n modules, converted to OSIS/UTF-8 from their stored formats and present them, verse by verse, in some clear & consistent format.
One such format might be:
<verse osisID="A:bk.ch.vs">text</verse> <verse osisID="B:bk.ch.vs">text</verse> <verse osisID="C:bk.ch.vs">text</verse>
<verse osisID="bk.ch.vs"> <seg type="x-parallel" subType="x-A">text</seg> <seg type="x-parallel" subType="x-B">text</seg> <seg type="x-parallel" subType="x-C">text</seg> </verse>
Front ends are then free to perform display however the like (or ignore the virtual module altogether, of course, if they prefer their own implementation.
Use wdiff on two translations to produce a word-by-word diff, which can then be rendered using different colors/styles. Quite similar to this: http://openscriptures.org/prototypes/manuscript-comparator/
Interlinear Virtual Module
Interlinearize texts on-the-fly, based on Strong's numbers. (Requires Strong's marked texts.)
Adding Strong's numbers virtually
Suggestion from DM, which generated some follow-up discussion.