[sword-svn] r406 - trunk
scribe at crosswire.org
scribe at crosswire.org
Mon Feb 7 12:27:14 MST 2005
Author: scribe
Date: 2005-02-07 12:27:13 -0700 (Mon, 07 Feb 2005)
New Revision: 406
Modified:
trunk/RxRichEditX.cpp
trunk/RxRichEditX.h
trunk/mainfrm.cpp
trunk/optionfrm.cpp
trunk/optionfrm.dfm
trunk/optionfrm.h
trunk/swdisprtfchap.cpp
trunk/sword.bpr
trunk/sword.res
Log:
Added display option to force a new line at start of each verse.
Modified: trunk/RxRichEditX.cpp
===================================================================
--- trunk/RxRichEditX.cpp 2005-01-12 10:21:27 UTC (rev 405)
+++ trunk/RxRichEditX.cpp 2005-02-07 19:27:13 UTC (rev 406)
@@ -615,6 +615,12 @@
attribs->markCurrentVerse = true;
else attribs->markCurrentVerse = (atoi(autoVSColor.c_str())) ? true : false;
+ //**** Mark Current Verse? ****//
+ SWBuf verseNewLine = Form1->optionsconf->Sections[dispType]["VerseNewLine"];
+ if (verseNewLine == "")
+ attribs->verseNewLine = false;
+ else attribs->verseNewLine = (atoi(verseNewLine.c_str())) ? true : false;
+
//**** Print Chapter Headings? ****//
SWBuf prChHeadings = Form1->optionsconf->Sections[dispType][(modType + "ChHead")];
if (prChHeadings == "")
Modified: trunk/RxRichEditX.h
===================================================================
--- trunk/RxRichEditX.h 2005-01-12 10:21:27 UTC (rev 405)
+++ trunk/RxRichEditX.h 2005-02-07 19:27:13 UTC (rev 406)
@@ -44,6 +44,7 @@
int lookupFieldColor; // Lookup Key Fields color
// Options
bool markCurrentVerse; // whether or not to mark current verse
+ bool verseNewLine; // whether or not to start each verse on a new line
bool prChHeadings; // Print Heading (Type Dependant)
bool prBookHeadings; // Print Book Name (Type Dependant)
bool prPreFix; // Print Verse Prefix (James 1:19 KJV) (Type Dependant)
Modified: trunk/mainfrm.cpp
===================================================================
--- trunk/mainfrm.cpp 2005-01-12 10:21:27 UTC (rev 405)
+++ trunk/mainfrm.cpp 2005-02-07 19:27:13 UTC (rev 406)
@@ -881,6 +881,7 @@
Optionsfrm->Label13->Caption = _tr("Verse Number Color");
Optionsfrm->btnNumClr->Caption = _tr("Select Color...");
Optionsfrm->AutoVSColor->Caption = _tr("Current Verse Color");
+ Optionsfrm->VerseNewLine->Caption = _tr("Start Each Verse On New Line");
Optionsfrm->btnCurrVerse->Caption = _tr("Select Color...");
Optionsfrm->Label15->Caption = _tr("Combo/Edit Fields");
Optionsfrm->btnFieldClr->Caption = _tr("Select Color...");
Modified: trunk/optionfrm.cpp
===================================================================
--- trunk/optionfrm.cpp 2005-01-12 10:21:27 UTC (rev 405)
+++ trunk/optionfrm.cpp 2005-02-07 19:27:13 UTC (rev 406)
@@ -286,6 +286,7 @@
emap = schemeconf.Sections["Appearance"];
emap.erase("AutoVSColor"); emap.insert(ConfigEntMap::value_type("AutoVSColor", IntToStr((AutoVSColor->Checked)?1:0).c_str()));
+ emap.erase("VerseNewLine"); emap.insert(ConfigEntMap::value_type("VerseNewLine", IntToStr((VerseNewLine->Checked)?1:0).c_str()));
emap.erase("CurrentVSColor"); emap.insert(ConfigEntMap::value_type("CurrentVSColor", IntToStr(shpCurrVSClr->Brush->Color).c_str()));
emap.erase("VSNumberColor"); emap.insert(ConfigEntMap::value_type("VSNumberColor", IntToStr(ColorDialogVerseNum->Color).c_str()));
emap.erase("FieldColor"); emap.insert(ConfigEntMap::value_type("FieldColor", IntToStr(ColorDialogField->Color).c_str()));
@@ -527,14 +528,12 @@
void TOptionsfrm::LoadDispSettings(SWConfig* config) {
SectionMap::iterator sit;
- SWBuf tmpval;
+ SWBuf tmpval;
- if((tmpval = config->Sections["Appearance"]["AutoVSColor"]) == "0"){
- AutoVSColor->Checked = false;
- }
- else {
- AutoVSColor->Checked = true;
- }
+ // default on
+ AutoVSColor->Checked = (config->Sections["Appearance"]["AutoVSColor"] != "0");
+ // default off
+ VerseNewLine->Checked = (config->Sections["Appearance"]["VerseNewLine"] == "1");
if((tmpval = config->Sections["Appearance"]["CurrentVSColor"]) != ""){
shpCurrVSClr->Brush->Color = TColor(atoi(tmpval.c_str()));
@@ -790,6 +789,7 @@
emap = config->Sections["Appearance"];
emap["AutoVSColor"] = IntToStr((Optionsfrm->AutoVSColor->Checked)?1:0).c_str();
+ emap["VerseNewLine"] = IntToStr((Optionsfrm->VerseNewLine->Checked)?1:0).c_str();
emap["CurrentVSColor"] = IntToStr(Optionsfrm->ColorDialogVS->Color).c_str();
emap["StrongsColor"] = IntToStr(Optionsfrm->ColorDialogStrongs->Color).c_str();
emap["MorphColor"] = IntToStr(Optionsfrm->ColorDialogMorph->Color).c_str();
Modified: trunk/optionfrm.dfm
===================================================================
(Binary files differ)
Modified: trunk/optionfrm.h
===================================================================
--- trunk/optionfrm.h 2005-01-12 10:21:27 UTC (rev 405)
+++ trunk/optionfrm.h 2005-02-07 19:27:13 UTC (rev 406)
@@ -104,6 +104,7 @@
TComboBox *genDictCB;
TLabel *Label17;
TCheckBox *HintVLists;
+ TCheckBox *VerseNewLine;
void __fastcall btnCurrVerseClick(TObject *Sender);
void __fastcall FormCreate(TObject *Sender);
void __fastcall FormShow(TObject *Sender);
Modified: trunk/swdisprtfchap.cpp
===================================================================
--- trunk/swdisprtfchap.cpp 2005-01-12 10:21:27 UTC (rev 405)
+++ trunk/swdisprtfchap.cpp 2005-02-07 19:27:13 UTC (rev 406)
@@ -106,6 +106,9 @@
}
else break;
} while (true);
+ if ((verse > 1) && (dispAttribs.verseNewLine)) {
+ newtext += "\\par ";
+ }
if (Module.Direction() == DIRECTION_RTL && (platformID == VER_PLATFORM_WIN32_WINDOWS || (Module.Lang() && strnicmp(Module.Lang(), "he", 2) && strnicmp(Module.Lang(), "ar", 2)))) {
newtext = newtext + RTFVersePre;
if ((key->Verse() == verse) && (dispAttribs.markCurrentVerse)) {
@@ -113,7 +116,8 @@
}
newtext += tmptext + RTFVersePost;
newtext = newtext + RTFVerseMarkPre + /*"<a href=\"\">" +*/ IntToStr(key->Verse()) /*+ "</a>"*/ + RTFVerseMarkPost;
- newtext = newtext + "\\par ";
+ if (!dispAttribs.verseNewLine)
+ newtext = newtext + "\\par ";
}
else {
newtext = newtext + RTFVerseMarkPre + /*"<a href=\"\">" +*/ IntToStr(key->Verse()) /*+ "</a>"*/ + RTFVerseMarkPost;
Modified: trunk/sword.bpr
===================================================================
--- trunk/sword.bpr 2005-01-12 10:21:27 UTC (rev 405)
+++ trunk/sword.bpr 2005-02-07 19:27:13 UTC (rev 406)
@@ -74,7 +74,7 @@
MajorVer=1
MinorVer=5
Release=6
-Build=10
+Build=13
Debug=0
PreRelease=0
Special=0
@@ -86,7 +86,7 @@
[Version Info Keys]
CompanyName=CrossWire Software & Bible Society
FileDescription=Windows 32bit User Interface to The SWORD Project
-FileVersion=1.5.6.10
+FileVersion=1.5.6.13
InternalName=biblecs
LegalCopyright=(c) 1990-2003 CrossWire Bible Society under the terms of the GNU General Public License
LegalTrademarks=
Modified: trunk/sword.res
===================================================================
(Binary files differ)
More information about the sword-cvs
mailing list