TMULTLANG PACKAGE FOR DELPHI v1.152 (C) 1995 Patrik Wang 12 June 1996 INDEX 1 Description 1.1 Features 2 Installation (Problems) 2.1 Files 2.2 Dependencis 2.3 Un-Installing 3 Shareware 4 Disclaimer 5 Register 5.1 Ordering 6 History 7 Author / Support 1 DESCRIPTION Forget Windows resource files (.RES, .RC ...) this component will make you internationalized without writing any additional code. Just drop it on your form and re-compile, finished. This component will translate properties in Delphi, at both design and runtime. Targeting bi-lingual and multi language support, but it can be used for many other things. Support for switching language at run-time independant of the running Windows version. This component will alter almost all properties that the object inspector can edit. You can choose if you want your languages to be saved in the form or a file. You can use the same file for all your form languages within the same application. It works in a multiuser environment and it is aware of other forms. You can share languages between different forms and manipulate those even at runtime. Come on and jump on the train to Rapid Application Development, it's lightening fast. Why use expensive tools to maintain different languages in C++ or other tools when you have this TMultLang package in Delphi. The MultLang package includes 12 components, the MExtras package described below and also the TComponentCollector(Full source) component. With this package you will be able to to make professional bi lingual applications. The MExtras package have 9 components that supports translation of all 16- and 32-bit common dialogs and one component for translating Message Boxes and Buttons. More information can be found in the MEXTRAS.TXT file. The ComponentCollector component hides all your Non-Visual components so they wont clutter your form. It is very useful when you use databases with many queries on the form. More information is provided in the COMPCOLL.TXT file. All components in our packages are pure Delphi components available in 16- and 32-bit. They are also cross-platform compatible 16<->32 bit and form file (*.dfm) compatible. You can safely depend on our components for Delphi in any environment, full source is also available to the public for all components. 1.1x FEATURES * Specialized for multi language support in Delphi. * Double byte languages support * Switching language at run-time independant of the running Windows version * Supports translation of Win 3.1 objects even when developing on Win 95 * Get multi lingual by just drop this VCL on a form (No additional coding) * Available as 16 and 32 bit with the fully source code in pure Delphi Pascal * Change text of almost all Component and Control properties * Support for translation of TStrings items and TFont objects * Multi-user shared resource file(s) (when an external file is used) * 16- and 32-bit Common dialogs support (without any DLL or RES files) * Delphi standard Message dialogs support (ShowMessage, MessageDlg, Input ...) * Write you own run-time property editor via INI files * Date, Time, Currency and Number format translations * Switch languages from selectable controls (Menus, DropDown, RadioGroup etc) * Save language translation in forms (design time) or external files * Even translates it self (Localized language names) * Aware of other forms within the same application * Objects and Properties browsable, just point and click * Share languages/properties/values between several forms * One run- and design-time editable resource file for one or more forms * Extensive help integrated with Delphi * Safe syncronisation when changing names, removing or inserting components * Associate icons (stretchable) to each configuration. * An easy property editor which is integrated in the Delphi environment. * Filter to restrict language translations (usable in a multi user environm.) * Supports translation of any language in Win 3.1, 95 and NT * Right-To-Left script translations * Add on's available for many different languages * 32-bit huge strings, >255 bytes (32-bit version) ***** MANY MORE FEATURES INCLUDED, PLEASE CHECK IT OUT YOURSELF ****** 2 INSTALLATION If you already have installed a previous version you will have to uninstall that one first. Please advice the old readme.txt file in the previous version. This installation installs both the TComponentCollector and the MExtras package, so if you already have one of them installed, please remove that component in the 'Install Components dialog' prior to this installation. STEP 1. First unpack MULTLANG.ZIP or MULTLAN2.ZIP in an own directory (you have probably already done that by reading this), this archive have subdirectories included. STEP 2. Move all *.HLP files to any directory in your search path, preferable the DELPHI\BIN directory where other Delphi helpfiles resides. STEP 3. Then install the MULTREG.PAS or MULTREG2.PAS file via the 'Install Component' menu option in Delphi. If any problems occurs, you can get your old library back from the backup file *.BAK that Delphi automatically makes (for more instructions see page 69 in the Users Guide). Please note that the Component path in this dialog is restricted to 255 characters (Delphi 1.0), this component must be in that path or the global Windows path. STEP 4. Install the MULTLANG.KWF and MEXTRAS.KWF files with the Helpfile installer program (HELPINST.EXE) supplied by Delphi. This enables you to press F1 in the Object Inspector to invoke help on that property. (Not necessary if you just want to have a quick look at the component). PROBLEMS !!!!! NOTE !!!!!! We recommend to increase the stack size from the standard 16384 bytes to at least 32768 in your large projects. If you plan to support editing of languages at run-time (Calling with the MultLang1.Edit(nil);) you must increase the stack size! However, we have concentrated on making the component as little memory consuming as possible, but we cannot change the Delphi Pascal object structures with the standard units that declares lot of global variables. The stacksize can be changed in the 'Options-Project' menu under the tab 'Linker' and also by using compiler directive {$M 32786 8192} in your source. It is not possible to adjust stack sizes in components, that's why we have to ask you to do it If you encounter "Outline Index Not Found" or "Invalid Index" while working in the Language Editor, please update your Delphi version. Apply latest free patches from Borland, the OUTLINE.DCU unit has several bugs that will be corrected when patched. This problem occurs if you are running the very first version of Delphi. If you have added several languages but they are not visible in the drop down list of the TMultLang component, please make the ItemHeight < Height and will show up in the list as it should. That's it !!!! Look at the Multi Lingual component palette in Delphi. Why not start with the Step-By-Step right away, the quick one takes only 5 min. Check the helpfile for more details by a right click on the TMultLang component at design time. For implementation details please advice the included technical papers named TECH*.TXT. They descibe important implementation methods and is highly recommended to read. Also please look at the sample project in the example subdirectory for advice and to look at source examples. 2.1 FILES These files is included in the TMultLang package. ADDPROP.DCU Compiled unit of the Add properties dialog. ADDPROP.DFM Add properties dialog. COMPCOLL.DCR Design time bitmaps for the TComponentCollecter COMPCOLL.DCU TComponentCollector component COMPCOLL.TXT Text file for the TComponentCollector COPYFROM.DCU Compiled unit of the Copy From dialog. COPYFROM.DFM Copy From dialog. LANGEDIT.DCU Compiled unit of the Language Property Editor dialog. LANGEDIT.DFM Language Property Editor dialog. MBUTTONS.DCU Multi language support component for Delphi standard buttons. MCOMBBOX.DCU DropDown component that supports Icons MDIALOGS.DCU The common dialogs multi language support. MEXTRAS.DCR Design-time bitmaps for the component palette (see MEXTRAS.TXT) MEXTRAS.HLP The MExtras package helpfile. MEXTRAS.KWF The MExtras keyword index for Delphi Help system. MEXTRAS.PAS MExtras installation file (Not needed, see MEXTRAS.TXT) MEXTRAS.TXT The MExtras instructions/registrations text file. MULABOUT.DCU Compiled unit for the About dialog. MULABOUT.DFM About dialog. MULTLANG.DCU Compiled unit for the TMultLang component (TMultLang component). MULTLANG.HLP TMultLang helpfile. MULTLANG.KWF TMultlang keyword index for Delphi Help system. MULTREG.DCR Design-time bitmaps for the component palette. MULTREG.PAS The component palette installation file. ORDER.HLP The order forms README.TXT Instructions/registrations text file (This file). REGFORM.DCU Compiled unit of the key registration form. REGFORM.DFM Key registration form. TECH*.TXT Technical papers (Based on FAQ) [EXAMPLE] Example directory, contains a MDI example project 2.2 DEPENDENCIES The units below must be available in the library search path when rebuilding the library. All used units are standard and is included in the Delphi package. I have tried to keep the dependent units to a minimum so that the overall size of your EXE will not be too big. You will probably need almost all units in your own project so it does not matter that it is used by this component. SysUtils, WinTypes, WinProcs, Messages, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, Menus, FileCtrl, DsgnIntf, TypInfo, OutLine, Tabs, ShellAPI, LibConst, LibHelp, ClipBrd, ExtCtrls, Buttons, Grids, TabNotBk, Mask, INIFiles; The units not included in the Delphi package is: AddProp, CopyFrom, LangEdit, MulAbout, RegForm; You dont need to include any of these in the USES clause, the component is already compiled. If you start with an empty project this component will add about 200K because of the dependencies, however the larger your project grows the less the component adds. If you have an EXE file for about 400K, by adding this component it may only grow to 515K because of the re-use of classes in Object pascal. 2.3 UN-INSTALL STEP 1. First remove the component from the component palette in Delphi via the 'Install Component' menu options in Delphi. STEP 2. Re-generate the keyword index for helpfiles in the Helpfile installer program (HELPINST.EXE) without the MULTLANG.KWF and MEXTRAS.KWF files. STEP 3. Just delete all files in the TMultLang package in the directory you choosed when it was installed. Dont forget to delete the helpfiles (MULTLANG.HLP and MEXTRAS.HLP) also, which is in the DELPHI\BIN directory if you installed it according to the installation instructions. 3 SHAREWARE This version of TMultLang is released as shareware and means in this case that you are allowed a trial period for testing. The testing period expires after 30 days from the installation time. After that period you have to remove it and must not use it anymore, or you can register it for continuing use. You are not allowed to make a new trial period by reinstalling the component again, unless it is a later version. We dont take any responsibility of misuse or of any corrupt files caused by this component and especially not your form files (*.DFM). It is your responsibility to always keep a backup copy of necessary files. For more info see page 139 'Creating a backup of an entire project' in the Delphi User's Guide. You are not allowed to modify any files associated with this component. In the Shareware version, you are allowed to distribute this component with all its files anytime. There is no limited functions in the Shareware version. This version is released based on trust, so I expect you to follow the rules. By using this component you accept the terms stated in this text file and the text shown in the 'About' dialog. 4 DISCLAIMER Users of TMultLang package must accept this disclaimer of warranty: "The TMultLang package is supplied as is. The author disclaims all warranties, expressed or implied, including, without limitation, the warranties of merchantability and of fitness for any purpose. The author assumes no liability for damages, direct or conse- quential, which may result from the use of the TMultLang package." Any reproduction of material in this package is copyrighted by law. The author reserves the right to change any text in this file, the helpfile and in the about dialog at anytime. 5 REGISTER By registering our TMultLang package you will get a license to use our package in your applications royalty free, besides that you will also get: * Lifetime support * Free minor upgrades * Upgrades to major new versions * Related information about Multi Lingual programming (Delphi) sent via E-Mail * Documentation * Free delivery (Air Mail) worldwide * Full source code to the TComponentCollector component Support will be given on the address below. Support will also be given to unregistered users within the trial period of the Shareware version. If you have access to Internet, please take a look at URL site http://www.windoze.com/delphi/ for late braking news and updates for the Multi Language Component. You will also get rid of all the annoying messages. The registration methods below entitles you to develop and distribute royalty free programs which contains this component package. Each registration allows one person to use the component at a time. Site registrations with more than 1 user are available with discounts. Please send us E-mail requesting a site licensing quote. 5.1 ORDERING When you order a product you will be E-Mailed a registration Key with instructions within 24 hours worldwide. For your convenience we have contracted NorthStar Solutions in USA to process any orders that you wish to place with your valid Visa or MasterCard. They may be contacted FOR ORDERS ONLY via any of the following methods: Voice: 1-800-699-6395 (10:00am - 10:00pm Eastern Standard Time US Only) 1-803-699-6395 (10:00am - 10:00pm Eastern Standard Time) Fax: 1-803-699-5465 (Available 24 hours. International) E-Mail: America Online: STARMAIL CompuServe: 71561,2751 Internet: STARMAIL@AOL.COM Regardless of how you register, please have the following information ready: * The name of the package listed below you are registering * Where the latest version should be mailed (E-Mail or Regular Post) * Your VISA or MasterCard # and its expiration date PLEASE NOTE: If you have any questions please send them to the Author on the address given below. NorthStar Solutions can only receive orders. If you have a CompuServe account you can also register a package On-Line, but we prefer receiving orders via NorthStar Solutions: NOTE CompuServe orders will have a surcharge of 15% on prices listed below. * Go to the SWREG forum and select Register Shareware. Search for TMultLang for the TMultLang package, or for MExtras for the TMExtras package, or for Collector for the TComponentCollector component, then select the version you would like to order. The price table below is valid til 1996-07-31. NAME (Delphi Component packages) PRICE TComponentCollector US$ 19 MExtras package US$ 29 Regular MultLang package 1.1x 16-bit * US$ 149 Regular MultLang package 1.1x 32-bit * US$ 149 Regular MultLang package 1.1x 16- and 32-bit * US$ 175 Source MultLang package 1.1x *, ** US$ 425 UPGRADES (Must provide previous license key) Regular MultLang package 1.1x -> 1.1x source. *, **, *** US$ 374 Regular MultLang package 1.1x 16-bit <-> 32 bit version *** US$ 75 * Also includes the MExtras package and the Collector component. ** The source includes both the 16 and 32 bit version. *** Previous license key must be quoted upon registration. We reserve the rights for price changes. 6 32-BIT VERSION The 32 bit version is fully compatible with 1.xx 16 bit versions of the multi language component. This means you can use the 16-bit component and later switch to the 32 bit component and then recompile, without any additional coding and re-translation. The 32-bit version adds on support for huge strings, but besides that all features are the same. This means full Form (*.dfm) format compability. You can for instance develop your application in a 32-bit environment (with Delphi 2.x) and then load your project in Delphi 1.x to just compile it for 16-bit without changing any code. 6.1 HISTORY 1.152 New features and Updates * Removed the %s in the Caption of the Browse dialog * Frequently asked questions (FAQ.TXT) file included * Removed unregistered reminder at design time (32-bit version) * New String command previously erased choosen properties (Browse dialog) * Order form for regular, source and site included (helpfile ORDER.HLP) * Removed a nasty bug that sometimes caused intermittent GPF`s * The DropDown text will no longer overlap in Windows 3.1x and NT * Language Editor layout changed, better crossplatform view * NEW Translate other forms within the Language Editor (if ext. file used) * The included example project is now using an external translation file * Bug removed, for adopted menu items * LanguageFile property variable %EXEPath% added, because Delphi changes working dir * Removed Caption translation for TTabbedNotebook (see FAQ.TXT for more info) * MButtons Update (Changed the Translate property, now only available at run-time) 1.151 Updates * Fixed a problem with TEXT files under 32-bit 1.15 New features and updates * User defined properties in the Browse dialog * Last property setting in the Browse dialog saved * Documentation updates * Helpfile updates * Localized version of German added * Added support for 32-bit (Delphi 2.x) * Huge string translation (>255 bytes) * Fixed an intermittent bug dealing with the TabControl 1.141 Updates * Example project updates * TComponentCollector Updates * README.TXT file update 1.14 General updates * Setting Font property of MDialogs could give GPF, bad OOP. Now corrected * Protected Invalid VBX Exception values * TMultLang properties could display duplicates in the Browse dialog * Forms did not sometime syncronize at design time when adding languages * Added support for Switch-To (TaskList) and Next Window in System Menus * Removed a bad BUG in the MDialogs components, when dropped on forms * Double Click in the Browse dialog did not work on the last property * New languages added * Right-To-Left script editing (Hebrew etc) in the Language Editor * MButtons bug, did not work with MDIChild windows, Corrected * Changing language via the tabs component if Adopted now works well * MFontDialog Font property now returns the selected Font * Updates to helpfiles and its keyword files * Included TComponentCollector (Hides non-visual components) * Now includes a sample project, many advanced features with source 1.131 Fixes * Debugging message '.LAN' removed, accidently included in the Trial pkg * About box version incorrect * MButtons component could loose translated strings sometimes 1.13 New features and Bug fixes * Double click on properties to transfer them over in the 'Browse' dialog * Fixed 'Invalid gridindex value' in the langauge editor dialog * MButtons sometimes gives a GPF in the initialize process, it is fixed * The brown color around the glyphs of buttons is corrected * Expand/Collapse now keeps the outlines syncronised in 'Browse' dialog * NEW, have substrings in all strings Ex. 'I like my %ComputerName%' * MButtons gave a GPF when closing the dialog if Translate=True * Selectable helpfile when editing other languages * Corrected a problem: exchanging items in the Outlines in 'Browse' * Added support for Dutch and Indonesian languages * Dbl_Click in the grid values did not save the values, 'Language Editor' * Resized some controls for longer language translations in it self * Helpfile updates MULTLANG.HLP and MEXTRAS.HLP (MEXTRAS.HLP included) * Updates of problems when using external file and it had the ext. 'lan' 1.12 Many new features and bug fixes * Calling Edit method several times could sometime cause a GPF * When translating fails it could give a GPF when TranslateApp was true * Bug in ORDER.EXE file occuring on Windows 3.1 'File not found' * External file handling routine bug when less memory available * Setting LanguageFile property to a language file at run-time caused GPF * Added support for System menu translation * All 16-bit Common dialog support via MDialogs.DCU component * Added support for translation of Number, Date, Time and Currency format * Localized Design-time interface, add your favorite language CTRL-ALT-E * Standard Message dialog buttons support via MButtons.DCU component * Property Recovery, put object back on form to get back translations * Import/Export of textfiles. Creates/Edits values. INI-file format * Userdefined strings, GetString and SetString methods * Copy from made unneccesary duplicates of properties when TStrings * Several updates for the main component regarding memory allocation * Helpfile updates 1.11 Bug fixes and new features * Setting caFree on child windows did not have any effect due to a bug in the subclassing of the window. Removed the unneccesary subclassing. * Translate method did not effect other forms, added TranslateApp variable * Deleting translated components at design-time could sometime give a GPF * The 'Copy From' selected language did not work as it should * Added the GetTranslation method * Helpfile updates * Added support for self translations, Localized language names * Updated prices, README.TXT and ORDER.EXE 1.10 Added new features and corrected two bugs. * A new property AdoptOn * The help system is totaly revised * Two step by step tutorials * Added Key words for Delphi * Grid style of values in the Property Editor * Copy property values from other forms. * File system totally revised (Also fixed the bug with NTFS partitions) * Less resource intence by reuse of string values * Look up table for soundex search of other forms values * Fixed a bug when editing Font names in the Property Editor * New Installation and un-install instructions in Help file * Many new topics added to help file * Expand All buttons added * Added a new property (FLookupText) for remembering the last state * Added a new property (FLastValue) for remembering the last sel. language * Removed the MASTAPP example which did not really show how it works * Removed the Simple and Advanced feature in the Property editor * Changed the display from date to Nr of days left in About (Shareware) * New registration rules and guidelines * It is now possible to have many TMultLang components on the same form 1.01 Updated instructions, was never really released to the public. 1.00 Initial release. 7 AUTHOR If you find any bug, please contact me and I will try to resolve it ASAP. If you have any suggestions or if you think I've missed something, I will happily implement that as an additional feature in future versions. I hope you will find the packages useful and easy to use. I am releasing it based on trust (Shareware) and even though you dont find it useful I would like to have your comments, bad or good. It is difficult to develop components without any suggestions, directions and the most important, knowing what people really need. Author: Patrik Wang Grenljusbacken 21 XI S-117 65 STOCKHOLM. SWEDEN E-Mail: PWang@MSN.COM Fax +46 8 7268142