[jsword-devel] JSword version and Indexing Jobs

Brian Fernandes infernalproteus at gmail.com
Fri Jan 25 23:03:40 MST 2008


DM,

1) Is it possible to query the JSword version through API? I did try a 
brief search but that drew a blank.

2) I'm really impressed with the speed of Lucene's searching/indexing 
already, am looking forward to the next version where it is so much faster.

On to my problem...
In my extension, I add a WorkListener to the JobManager during indexing 
so that I may monitor and report progress. In #workProgressed, I update 
my progress bar with the section name from the job. This works perfectly.

However, unlike BibleDesktop, my progress bar is small, perhaps 100 
pixels wide. The job section names during indexing are something like 
"Creating Index. Processing Genesis" and so on, sometimes the text 
overflows out of the progress boundaries region depending on length of 
the book name. I would probably display just "Indexing Genesis" for my 
small progress bar.
This would be an easy mod if the text was always going to be "Creating 
Index. Processing X", but since JSword is I18Ned, it is not so easy to 
arrive at a generic solution.
Would it be possible to change the job section name to just "Genesis" 
instead, the rest of the description to be managed by a UI element? I 
realize that the job is not always in the "Creating Index" phase and it 
could be Optimizing as well (and this would change the "complete" 
description in the UI) but hopefully that phase can be ascertained by 
looking at the completion percentage.

Am open to any other suggestions you may have to deal with this issue.

Keep up the great work with  JSword, has been a real pleasure working 
with it.
Brian.



More information about the jsword-devel mailing list