Re: [sword-devel] Magic testament numbers in Sword

2017-03-22 Thread Jaak Ristioja
I think you might have misunderstood my question.

I'm simply puzzled about the code and whether the value 0 for char
testmt is even used somewhere? Why isn't the testmt parameter an enum {
NewTestament, OldTestament } type?

J

On 19.03.2017 23:51, DM Smith wrote:
> I’ve always wanted to know the answer to that too. Osis2mod can’t handle 
> Bible or Testament introductions as it (meaning me, since I code it) doesn’t 
> know how to construct an address for them. Not sure how any front end 
> addresses them.
> 
> From memory and I may not have this right:
> The idx files for the OT and NT have index 0 for the module introduction and 
> index 1 for the testament introduction. Index 1  the address of testament #, 
> book 0, chapter 0, verse 0.
> 
> Index 2 is for the introduction for the first book of the testament. 
> Addressed as testament #, book 1, chapter 0, verse 0.
> 
> Index 3 is for the introduction of the first chapter of that book. Addressed 
> as testament #, book 1, chapter 1, verse 0.
> 
> Index 4 is for the first verse of the first chapter of the first book of the 
> testament. Addressed as testement #, book 1, chapter 1, verse 1.
> 
> If you have a single testament, the module introduction is in that testament.
> 
> But I’ve never seen an example of module or testament intros working.
> 
> DM
> 
>> On Mar 19, 2017, at 5:33 PM, Jaak Ristioja  wrote:
>>
>> Hello!
>>
>> I have a question about a magic number in the zVerse, zVerse4, RawVerse
>> and RawVerse4 classes. More precisely, some of their methods take as
>> argument a variable "testmt" of type char. For some methods the code
>> comments states:
>>
>>  testmt- testament to find (0 - Bible/module introduction)
>>
>> but for other methods:
>>
>>  testmt  - testament file to search in (0 - Old; 1 - New)
>>
>> Am I correct that the code comments is outdated with respect to the
>> code, and it should actually read something like:
>>
>>  (0 - Bible/Module introduction; 1 - Old Testament, 2 - New Testament)
>>
>>
>> Thanks,
>> J
>>
>> ___
>> sword-devel mailing list: sword-devel@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@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@crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page

Re: [sword-devel] Magic testament numbers in Sword

2017-03-20 Thread David Haslam
I wonder how *xulsword* manages this?

Some IBT modules are quite heavy on "book introductions", so it might be
expected to see "testament intros" too.

Then what about modules containing DC books?

Providing they're not interspersed in the OT books, but a distinct block
between OT and NT, shouldn't the DC block be treated separately as a
*majorSection div* (as we will do for the next release of KJVA)?

And if a majorSection div, then why not make SWORD support an intro for a
majorSection, irrespective of whether it's a "testament" or not?

Best regards,

David



--
View this message in context: 
http://sword-dev.350566.n4.nabble.com/Magic-testament-numbers-in-Sword-tp4656984p4656986.html
Sent from the SWORD Dev mailing list archive at Nabble.com.

___
sword-devel mailing list: sword-devel@crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page


Re: [sword-devel] Magic testament numbers in Sword

2017-03-19 Thread DM Smith
I’ve always wanted to know the answer to that too. Osis2mod can’t handle Bible 
or Testament introductions as it (meaning me, since I code it) doesn’t know how 
to construct an address for them. Not sure how any front end addresses them.

From memory and I may not have this right:
The idx files for the OT and NT have index 0 for the module introduction and 
index 1 for the testament introduction. Index 1  the address of testament #, 
book 0, chapter 0, verse 0.

Index 2 is for the introduction for the first book of the testament. Addressed 
as testament #, book 1, chapter 0, verse 0.

Index 3 is for the introduction of the first chapter of that book. Addressed as 
testament #, book 1, chapter 1, verse 0.

Index 4 is for the first verse of the first chapter of the first book of the 
testament. Addressed as testement #, book 1, chapter 1, verse 1.

If you have a single testament, the module introduction is in that testament.

But I’ve never seen an example of module or testament intros working.

DM

> On Mar 19, 2017, at 5:33 PM, Jaak Ristioja  wrote:
> 
> Hello!
> 
> I have a question about a magic number in the zVerse, zVerse4, RawVerse
> and RawVerse4 classes. More precisely, some of their methods take as
> argument a variable "testmt" of type char. For some methods the code
> comments states:
> 
>  testmt- testament to find (0 - Bible/module introduction)
> 
> but for other methods:
> 
>  testmt  - testament file to search in (0 - Old; 1 - New)
> 
> Am I correct that the code comments is outdated with respect to the
> code, and it should actually read something like:
> 
>  (0 - Bible/Module introduction; 1 - Old Testament, 2 - New Testament)
> 
> 
> Thanks,
> J
> 
> ___
> sword-devel mailing list: sword-devel@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@crosswire.org
http://www.crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page