----------------------------------------------------------------
LBA Text Editor 2
 editing lbt (text) files from Little Big Adventure 1 & 2

Copyright (C) Zink

     Version: 2.3
Release date: 16.11.2011
     License: GPL (free)
      E-mail: kazink@gmail.com - any feedback is welcome
   Home site: lba.kazekr.net - latest version always there

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details (License.txt).
----------------------------------------------------------------

####################################
 1. Manual
####################################

 This manual is short because of lack of time. In addition author informs, that he doesn't have "Writing Manuals" skill :), so it'll probably stay as is. 


 A. Opening files
------------------

 To open a file to edit, you may:
  - click File->Open..., or
  - click the button with folder picture, or
  - drag a LBA text file onto program's icon when it isn't running, or 
  - drag a LBA text file onto program's window.

 After opening all the texts from the file are visible in the main window (you can use scrollbar on the right to scroll them), if you want to edit any text, double click on it or select it and click the "Edit seleceted entry" item from "File" menu. 

 
 B. Editing files
------------------

 You can work in two editing modes: 
  - Editor in the same window - can be enabled by checking apropriate option in "Options" menu. In this mode the text is able to edit inside the main program window. You can use additional options from the panel appearing on the left side of the window when you enter the editing mode. The "On edit box exit" box allows you to specify whether the changes shall be saved or discarded when you select another text or click something outside the editor box and the panel.
  - Editor in a separate window - shows up if the internal editor is disabled. It has almost the same options as the internal editor.


 C. Searching and replacing
---------------------------- 

 Click Edit->Find, enter the string you want to search and click <Find>. If searched expression isn't found, the information will pop up. If expression is found, selection will move to the text which contains it. If you open this text to edit, the searched fragment will be selected. 
 If you click Edit->Find next, program will search the next text, that contains searched expression, regardless of how many times searched expression repeats in current text.
 If you click the button with magnifying glass with an arrow while you are in the edit window, program will search next instance of searched string only in currently opened text. The <Find> button also relates ONLY to current opened text.

 IMPORTANT: After clicking the "Find" menu item searching begins ALWAYS form the beginning of the first text, regardless of whitch text is currently selected.
 IMPORTANT 2: Always the EXACT text you write is searched - with spaces and commas altogether.

 If you want to replace any string with some other, click Edit->"Find and replace", and enter desired strings, than click <Replace all> button. This will replace all occurences of the searched string in ALL texts.


 D. Using the translator mode
------------------------------

 In this mode you can link two or more instances of the program so that if you selected a text in one of them, the second one would select the text with the same index. 
 You can open more than one copies of the program and when you select an entry in one of them, the other ones will select the same entries depending on settings. This is useful during translating: you can open translated text in one window and original text in another window, and you will not have to select and scroll texts in both windows, but only in one of them.

 The translator mode can be enabled in "Options" menu. You can run it in four modes:
 - Send commands - the program will send to the other ones the number of selected entry, but it will not respond to selecting entries in other program instances.
 - Receive commands - the program will be selecting entries with index numbers got from other program inastance (if they has an apropriate option enabled), but it will not be sending such indexes to other instances.
 - Send and receive commands - the program will be sending indexes of selected entries to other instances and will be selecting entries with indexes got from other instances.
 - Off - the program will neither send index numbers nor receive them. 
 
 Current translator mode is not saved when program exits, and the "Off" option is always checked at the program start.

Remark: Because this feature seems to be hard to understand, I put here an explanation I have given to my friend who also couldn't get it:
 Run the program twice, then open one file with both of them, then set first one to "Send commands" and the other one to "Receive commands". Then click on some texts in the first one, and you'll see that the second one selects the same texts automatically.


 E. Using the preview feature
------------------------------

 Click Edit->"Preview selected text" to see how selected text will look in LBA. 
 Note that the lines arrangement in the preview may not match the one in real LBA.
 There are several options, you will know them best when you try them ;) 


 F. Using conversion maps
--------------------------
 
 You may customize the way in which characters are displayed in the main window. National characters have different codes in Windows and LBA. A conversion map converts characters of loaded file from LBA standard to Windows standard, and converts them back when you save, so that you can see your national characters in the Editor instead of some weird characters.

 In the "Conversion map" menu you may choose what conversion map will be used. "None" means that no characters will be converted during loading nor saving a text file.

 Note that if you change the conversion map when you have a text file opened, you will have to reload the text to make the map working for current file. Otherwise the file may be saved with different characters than it had before.
 
 Conversion map displays which characters are converted into other ones. The map may be viewed in two modes. Changes made in one mode are automatically translated into another one, so you can switch between modes freely.
 - The table view tab displays conversion map as a table which column and row labels mean the codes of all characters, and items mean the codes that apropriate characters will be converted to. For example: If you want to know what code the character $5A will have when you load it, you have to look at the first column of the table and seek for row labeled "50", then you look at first row and seek for column labeled "A". At the intersection of the row 50 and column "A" you will find the character that character $5A will be converted to. When you load a file, all characters with codes $5A are converted to character you found, and when you save a file, all characters with code you found are converted to $5A. 
 - The list view tab displays conversion map as a list of conversions. It directly shows which charecters are converted to which ones. The characters that are not on the list are not converted.

 In "Edit when" box you may specify when the editing has to begin: If "Clicked" is checked, editing will start when you click on an item (cell of the table or item of the list). If "Dbl. clicked" is checked, you have to double click items to edit them.
 
 In "On edit box exit" box you may specify whether the value you entered has to be saved or discarded when you are in editing mode and you click something outside the editor box.


 G. Editing file stucture
--------------------------
 
 To enable file structure editing you have to uncheck "Lock file structure" item in the "Edit" menu. 
  
 Then you can move, add and delete entries ("Edit" menu), however this is not recommended until you have reason to do that.

 H. How to make your own program translation
---------------------------------------------

 Open "example.lng" file with any text editor. You just have to translate all the texts you find inside. Then you can give the file the name of your choice.

 To open language file click Language->"From file...".

 Note that I AM NOT RESPONSIBLE FOR ANY CUSTOM TRANSLATIONS AND FOR ANY INTELECTUAL OR PHYSICAL DAMAGES THEY CAN CAUSE.


 I. Note on autodetection feature
----------------------------------

 Autodetection was tested with all original english texts from both LBA 1 and 2. However if it doesn't work properly for you, you can disable it in the "Options" menu and I would appreciate your information about such fact.


####################################
 2. Thanks to
####################################

 - AlexFont - for entirety ;)
 - pkome - for Chinese translation