|
| No member browsing this thread |
|
Thread Status: Active Total posts in this thread: 6 |
|
| Author |
|
|
Stranger China Joined: Apr 29, 2009 Post Count: 2 Status: Offline |
I want to write a Sword extension for Sphinx. The extension can help on Bible study by this way: If I type :bible:`Genesis 1:1` In the beginning God created the heavens and the earth. So I need to know, is it possible to call a command generating the previous line with argument of "Genesis 1:1" or something similar? And if the command can select Bible texts module, such as ChiNCVs or ASV, it would be even better. If there is no such convenient command, could you point me to some materials with which I can write a simple script. Except an API primer, I don't find any other document like man page or help file of Sword. |
||
|
|
Inventory Germany Joined: Jun 12, 2008 Post Count: 637 Status: Offline |
IMO there is no command line tool except diatheke that can do this right away. In the sources are some simple examples of how to do what you like: https://crosswire.org/svn/sword/trunk/examples/simple.cpp Regards, Manfred |
||
|
|
Stranger China Joined: Apr 29, 2009 Post Count: 2 Status: Offline |
Thank you very much Best wishes, Wei-Wei |
||
|
|
Stranger Argentina Joined: May 10, 2011 Post Count: 4 Status: Offline |
I installed the Darby module, and then successfully compiled the simple.cpp example using a Makefile I found at the examples directory. When I run it, it doesn't print anything at all. If the module wasn't properly installed I should be getting a segmentation fault, instead the program ends normally without printing anything to STDOUT (echo $? returns 0). I'm using ubuntu 10.04, and I compiled the project from source. Any help would be greatly appreciated. regards, Jonathan |
||
|
|
Stranger Argentina Joined: May 10, 2011 Post Count: 4 Status: Offline |
If I cast it to (const char *) as the API primer suggests as an alternative, I get garbage printed instead. |
||
|
|
Stranger United States Joined: May 14, 2011 Post Count: 2 Status: Offline |
IMO there is no command line tool except diatheke that can do this right away. In the sources are some simple examples of how to do what you like: https://crosswire.org/svn/sword/trunk/examples/simple.cpp Regards, Manfred Thanks for this one Manfred. |
||
|
|
|
|
Current timezone is GMT May 22, 2013 8:11:22 AM |