[sword-devel] ncurses-based version

sword-devel@crosswire.org sword-devel@crosswire.org
Thu, 27 Jan 2000 20:49:45 +1300 (NZDT)


Have I missed something here?  Is anyone else working on an ncurses
based version at the moment?  Here are my current thoughts on an ncurses
version.  It's not complete but it should give you a gist of where I am


This is a preliminary document about my intentions to design an ncurses
bible software program using the ncurses library.  I eventually succeeded in
compiling sword on my laptop but not without a Redhat 4.1 -> Redhat 6.0
upgrade.  This took 2 days to do as there is no CD-Rom drive on my laptop
and I had to set up a PLIP driver to do it.  Please feel free to comment on
anything I've written down here.  Nothing is as yet hard and fast. 
Everything is open to change.

I also want to put this documentation up on my web page at some point for a
common reference point.

What is this all about?

A bible software program which uses the ncurses library.  One which can be
used over telnet connections or over a minicom (modem) connection.  It will
use the sword library.  It will be open source and use the GNU liscence.

What shall I call it?

Not sure yet.  The one I am thinking about is "Truth 2000".  Has anyone got
a better name?  The name is based on Luke 1:4 as translated in the New
American Standard Translation.

Luke 1:4 so that you might know the __exact truth__ about the things you have
been taught.

I've even thought about calling it "Exact Truth 2000" but maybe this would
be a bit pretentious.

How is it going to be designed?

The basic idea is that it should be implemented in such a way as to get a
working prototype up as quickly as reasonably possible.  I do not wish to
compromise the design by coding too early but an initial prototype will help
guage what further considerations may need to be taken into account.  (eg. 
What happens when it is run on a sparc or a Dec Alpha.  I don't have access
to these).

Also I am not intending to make this a one man project and if anyone wants
to help me out here that would be much appreciated.  However in order to get
things started I will be putting out a fair amount of documentation on both
the user side and the technical design side.  I intend to even attempt to
document the way I see the code interfaces working to facilitate the
previous mentioned design by other people.  None of this need be fixed, by
myself, but in the interests of making a start I am going to make a start.

How does it work?


I think an Ncurses bible program should be light weight.  For instance able
to run comfortably on a 486 laptop with 12MB of memory springs to mind.  ;)
(This is what I have).

Basic Bible functionality

* Implement bible with Ncurses functionality with colour and mouse support
but none of these being essential requirements.

* At least two types of keyboard mappings handled by a configuration file. 
One for "at the computer" with Page Up and Page Down keys chosen as the
default mapping.  One for telnet and perhaps using something similar to the
wordstar key mappings or those used by the 'joe' editor.  Perhaps using a 
key mappings file with settings something like:

Page-Up		<ESC>[5~
Page-Down	<ESC>[6~
Up-Arrow	<ESC>[A
Down-Arrow	<ESC>[B

and these can be changed by editing a text file or selecting another premade
text file.

Someone made a suggestion to use the terminfo library for this instead and
then just set the environment variable.

I take it ....

export TERM

but someone may be able to advise me more accurately on this.

* Reference List based bible.

This is just an idea I've been thinking about after seeing some deficiencies
in some older bible programs.  (I don't know how the bibletime computer
software works as I haven't downloaded it except for a couple of
screenshots.  I also don't __yet__ have a computer powerful enough to use

The basic building block of the user interface being the reference list. 
The reference list is a window containing a list of scriptures relating to a
central idea.  This isn't a rigid thing.  It might be, for instance,
scriptures I have been thinking about last Tuesday.  But its also based
around the way the Holy Spirit seems to work.  Often I will receive
scriptures along a central theme and I will be given a number of scriptures
which relate along a common phrase, idea, symbol or figure.  Because these
are personal revelations of scripture they may not be covered in coventional
commentaries and such.  However for the purposes of the program the
reference list is simply a window containing scripture references with user
entered annotated text attached to that window.  This is over and above
annotated text attached to individual verses.

There can exist more than one reference list but there must exist at least
one.  I can call this the Main Reference List window.  Scripture references
can be moved to and from reference lists at will.  These Reference Lists are
permanent and so do not finish upon exiting of the program.  So perhaps I
should call them something else rather than a window.  For now I will just
call them a reference list.

Relationship lines can also be added between two or more reference lists
with again anotated texts.  These also are permanent.

Reference lists can contain references to scripture translations,
commentaries and dictionaries.

* Included Notepad Editor for making notes about references lists, or
verses, other commentary references, etc.  Uses key mapping file.

* Quickly find a reference list from a list of user annotated text. 
Basically a reverse index of some sort.

* Quickly find a user annotated reference from a list of the user annotated
text.  Again a reverse index.

Some dummy text screens - sort of
This won't look right if you're using proportional fonts.

I imagine the screens will look something like this.

+- NASB -(Luke)-----------------------------------------------------+
|								    |
| 1:3 it seemed fitting for me as well, having investigated 	    |
| everything carefully from the beginning, to write {it} out for    |
| you in consecutive order, most excellent Theophilus;		    |
|								    |
| 1:4 so that you might know the exact truth about the things you   |
| have been taught.						    |
|								    |
+- NIV -------------------------------------------------------------+
|								    |
|								    |
|								    |
|								    |
|								    |
+- KJV -------------------------------------------------------------+
|								    |
|								    |
|								    |
|								    |
|								    |

The idea is that three translation should be able to be viewed at once.

I envisage reference lists, perhaps looking something like:

|								    |
|   REF	 Topic = "God's Power"                                      |
|   ---                                          		    |
|                                                                   |
|   + Matthew 8:17                                                  |
|   + Luke 1:3          (3 notes, 2 xref)                           |
|   + Phillipians 4:7                                               |
|                                                                   |
|                                                                   |
|                                                                   |
|                                                                   |
+- Notepad ---------------------------------------------------------+
|                                                                   |
|                                                                   |
|                                                                   |
|                                                                   |
|  F2 = New Ref        F4 = Switch to Notepad/Ref                   |
|  F3 = Remove Ref     <ENTER> = expand/view reference              |

Other things I haven't thought through yet.

* Speech Synthesis (???)

* Voice Recognition (???)

* I would also like to make my data files, inasmuch as possible, in some way
compatible with Bibletime and other GPL bibles.  So you can exchange
reference list notes (Import \ Export) between each program.

On Wed, 26 Jan 2000, Ted Rolle wrote:

> Does this mean "make it look like linuxconf"?  My X11 is broken (all I can
> get is 4-bit color -- it's useless).  However, linuxconf looks quite nice
> without the X interface; is this a curses interface?
> First-time surrealists are often confused by the similarities between fish and telephones.