[jsword-devel] Lexical Word form in MorphGNT

DM Smith dmsmith555 at yahoo.com
Wed May 14 13:11:16 MST 2008


On May 14, 2008, at 3:44 PM, Mullins, Steven wrote:

> DM,
>
> I think that it is a good idea to define a protocol for lex.  There  
> are a
> few Greek lexicons in the sword modules that it "could" link to with
> a bit of work.  The lexicons are upper-case and the lexical forms are
> lower, besides the Unicode issues involved.  But I think it can be  
> done.
> I don't have any hyperlinks in the xls code for lex, but that would be
> a nice function to put in later, when the protocol is working.

The basic idea is that the keys of all dictionaries are ordered by  
either bytes (for the case of so-called Latin1) or by code points (for  
unicode). We assume NFC normalization for all Unicode. Fortunately,  
ordering by code points is identical to ordering by bytes.

One caveat, the keys so far have been ascii or latin 1. There may be  
bugs to be found when we get lexicons with keys that are non-ascii in  
unicode.

At some point we will probably need to bring in icu4j to do  
normalization of user input so that we can do a unicode search.

Ultimately, we want to be able to create a rich index on dictionaries,  
which also includes multiple representations of the key: Decorated,  
undecorated, transliterated/romanized, NFC normalized, and perhaps  
others. Then a key lookup would be simple.

This would be a lucene index.


>
>
> Yes the OSISUtil code is dead.  It was an artifact of an earlier  
> attempt
> that I aborted.  It should be discarded.

Done.

>
>
> I think defaulting all non-strongs to display as [lex] will work good
> for now.  Later, if hyperlinks are added in the xls code for linking
> to lexicon modules, another catch-all bin can be set up.

Good idea.

>
>
> Since I am very new to jsword, what is the best way to contribute  
> code?

Find something that interests you, discuss it on jsword-devel, make  
the changes, submit a zipped patch here. It is also good to create an  
issue in our issue tracker.And later, we may want to attach patches to  
the issues. Currently, Jira, our issue tracker, is down and it may be  
in the process of being replaced.

By and large, I am open to most changes as long as they fit in with  
how JSword/BibleDesktop is written.

BWT, this is what you did. Except for zipping the patch. :)

I have checked in your changes and am in the process of building on  
the server right now.


>
>
> Looking forward to helping.  I'm glad to return a little bit of work  
> back
> the Biblical Open Source community, since I have benefited so much  
> from it.

I'm looking forward to it to!

In Him,
	DM
>
>
> Thanks,
>
> Steve
>
>
> Steve,
> Good timing! This will make it into the release. I am in the process  
> of
> committing your change.
>
> I've applied the change to simple.xsl with a minor change to create a
> variable lex.def.protocol whose value is 'lex:' and use that.
>
> I didn't apply the patch to OSISUtil as it would be dead code. The new
> stuff is not used anywhere. Was there something else that should be
> included in the patch?
>
> It would be easier for me if the patch is attached as a zip.
>
> I think it would be good to make a minor modification to your code  
> that
> rather than looking for lemma.Strong, it is the default for all lemmas
> that are not Strong's numbers. This would handle two types of values:
> lemma="A:B"
> and
> lemma="B"
> both outputting [B], where A is not in strong: and x-Strongs:
>
> Looking forward to more contributions!
>
> DM
>
> On May 14, 2008, at 12:32 PM, Mullins, Steven wrote:
>
> This is my first code contribution to this project.  Woo Hoo!
>
> Right now in the MorphGNT module, if Strongs numbers are checked  
> yes, nothing is shown.  This is because in the MorphGNT module, the  
> value for the strongs numbers in the source is not a strongs number,  
> it is the dictionary (lexical) form of the word.  With this code  
> added, and strongs checked yes, the lexical form will display inline  
> in square brackets.  The other modules do not appear to be affected.
>
> Changes were made based on revision 1859.




More information about the jsword-devel mailing list