VERSION 5.00 Object = "{723C13CC-FA83-4FCA-915A-9ECA87DF11A1}#1.0#0"; "ACTIVE~1.OCX" Object = "{3B7C8863-D78F-101B-B9B5-04021C009402}#1.2#0"; "RICHTX32.OCX" Begin VB.Form MainWindow BorderStyle = 3 'Fixed Dialog Caption = "ActiveDiatheke Demo" ClientHeight = 7680 ClientLeft = 45 ClientTop = 330 ClientWidth = 10080 LinkTopic = "Form1" MaxButton = 0 'False ScaleHeight = 7680 ScaleWidth = 10080 StartUpPosition = 3 'Windows Default Begin VB.CheckBox bidireorder Caption = "BiDi Reorder" Height = 255 Left = 3360 TabIndex = 18 Top = 600 Width = 1455 End Begin VB.CheckBox arshape Caption = "Shape Arabic" Height = 255 Left = 1920 TabIndex = 17 Top = 600 Width = 1335 End Begin VB.CheckBox script Caption = "Roman Transliterate" Height = 255 Left = 4920 TabIndex = 16 Top = 600 Width = 1815 End Begin VB.CheckBox variants Caption = "Variants" Height = 255 Left = 7680 TabIndex = 15 Top = 840 Width = 975 End Begin VB.CheckBox scripref Caption = "Scrip. Refs." Height = 255 Left = 8760 TabIndex = 14 Top = 840 Width = 1335 End Begin VB.CheckBox gaccents Caption = "Greek Accents" Height = 255 Left = 1920 TabIndex = 13 Top = 840 Width = 1455 End Begin VB.CheckBox hpoints Caption = "Hebrew Vowels" Height = 255 Left = 3360 TabIndex = 12 Top = 840 Width = 1455 End Begin VB.CheckBox hcantillation Caption = "Hebrew Cantillation" Height = 255 Left = 4920 TabIndex = 11 Top = 840 Width = 1815 End Begin VB.CheckBox morphology Caption = "Morphology" Height = 255 Left = 8760 TabIndex = 10 Top = 480 Width = 1335 End Begin ACTIVEDIATHEKELib.ActiveDiatheke diatheke Left = 0 Top = 6720 _Version = 65536 _ExtentX = 3625 _ExtentY = 1085 _StockProps = 0 book = "" key = "" script = "Latin" strongs = -1 'True footnotes = -1 'True headings = -1 'True morphology = -1 'True greekaccents = -1 'True hebrewpoints = -1 'True hebrewcantillation= -1 'True scripref = -1 'True arshape = -1 'True bidireorder = -1 'True outputformat = 5 outputencoding = 4 End Begin RichTextLib.RichTextBox presentation DataField = "5" Height = 6495 Left = 1800 TabIndex = 9 Top = 1200 Width = 8295 _ExtentX = 14631 _ExtentY = 11456 _Version = 393217 Enabled = -1 'True ScrollBars = 2 TextRTF = $"ADDemo.frx":0000 End Begin VB.CheckBox headings Caption = "Headings" Height = 255 Left = 7680 TabIndex = 8 Top = 480 Width = 1095 End Begin VB.CheckBox footnotes Caption = "Footnotes" Height = 255 Left = 8760 TabIndex = 7 Top = 120 Width = 1095 End Begin VB.CheckBox strongs Caption = "Strong's" Height = 255 Left = 7680 TabIndex = 6 Top = 120 Width = 975 End Begin VB.ComboBox searchtype Height = 315 Left = 6120 TabIndex = 4 Top = 120 Width = 1455 End Begin VB.TextBox key CausesValidation= 0 'False Height = 375 Left = 2280 TabIndex = 1 Top = 120 Width = 2535 End Begin VB.ListBox books Height = 7665 Left = 0 TabIndex = 0 Top = 0 Width = 1815 End Begin VB.Label Label3 Caption = "Search Type" Height = 255 Left = 5040 TabIndex = 5 Top = 120 Width = 975 End Begin VB.Label Label2 Caption = "Key" Height = 255 Left = 1920 TabIndex = 3 Top = 120 Width = 375 End Begin VB.Label Label1 Caption = "Label1" Height = 135 Left = 3960 TabIndex = 2 Top = 120 Width = 15 End End Attribute VB_Name = "MainWindow" Attribute VB_GlobalNameSpace = False Attribute VB_Creatable = False Attribute VB_PredeclaredId = True Attribute VB_Exposed = False Private Sub arshape_Click() If arshape.Value = 1 Then diatheke.arshape = True Else diatheke.arshape = False End Sub Private Sub bidireorder_Click() If bidireorder.Value = 1 Then diatheke.bidireorder = True Else diatheke.bidireorder = False End Sub Private Sub books_Click() diatheke.book = books.Text End Sub Private Sub diatheke_ValueChanged() presentation.TextRTF = diatheke.Value End Sub Private Sub footnotes_Click() If footnotes.Value = 1 Then diatheke.footnotes = True Else diatheke.footnotes = False End Sub Private Sub Form_Initialize() ' grab the book list (just names) using book "system" and key "modulelistnames" diatheke.book = "system" diatheke.key = "modulelistnames" diatheke.query ' split the book list by line into an array booklist = Split(diatheke.Value, Chr$(10), -1, vbTextCompare) ' and add them each to the list control For Each book In booklist books.AddItem (book) Next book diatheke.book = "KJV" diatheke.key = "John 1:1" diatheke.query ' wasn't that easy :) key.Text = diatheke.key searchtype.AddItem "None", 0 searchtype.AddItem "Regex", 1 searchtype.AddItem "Multiword", 2 searchtype.AddItem "Phrase", 3 searchtype.ListIndex = diatheke.searchtype key.Text = diatheke.key If diatheke.strongs Then strongs.Value = 1 Else strongs.Value = 0 If diatheke.footnotes Then footnotes.Value = 1 Else footnotes.Value = 0 If diatheke.headings Then headings.Value = 1 Else headings.Value = 0 If diatheke.morphology Then morphology.Value = 1 Else morphology.Value = 0 If diatheke.scripref Then scripref.Value = 1 Else scripref.Value = 0 If diatheke.variants Then variants.Value = 1 Else variants.Value = 0 If diatheke.script = "Latin" Then script.Value = 1 Else script.Value = 0 If diatheke.arshape Then arshape.Value = 1 Else arshape.Value = 0 If diatheke.bidireorder Then bidireorder.Value = 1 Else bidireorder.Value = 0 diatheke.autoupdate = True End Sub Private Sub Form_Terminate() diatheke.autoupdate = False End Sub Private Sub gaccents_Click() If gaccents.Value = 1 Then diatheke.gaccents = True Else diatheke.headings = False End Sub Private Sub hcantillation_Click() If hcantillation.Value = 1 Then diatheke.hcantillation = True Else diatheke.hcantillation = False End Sub Private Sub headings_Click() If headings.Value = 1 Then diatheke.headings = True Else diatheke.headings = False End Sub Private Sub hpoints_Click() If hpoints.Value = 1 Then diatheke.hpoints = True Else diatheke.hpoints = False End Sub Private Sub key_Change() diatheke.autoupdate = False diatheke.key = key.Text diatheke.autoupdate = True End Sub Private Sub key_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then diatheke.query End Sub Private Sub morphology_Click() If morphology.Value = 1 Then diatheke.morphology = True Else diatheke.morphology = False End Sub Private Sub scripref_Click() If scripref.Value = 1 Then diatheke.scripref = True Else diatheke.scripref = False End Sub Private Sub searchtype_Change() diatheke.searchtype = searchtype.ListIndex End Sub Private Sub strongs_Click() If strongs.Value = 1 Then diatheke.strongs = True Else diatheke.strongs = False End Sub Private Sub script_Click() If script.Value = 1 Then diatheke.script = "Latin" Else diatheke.script = "Off" End Sub Private Sub variants_Click() If variants.Value = 1 Then diatheke.variants = 1 Else diatheke.variants = 0 End Sub