Emiel Wieldraaijer Posted February 26, 2007 Share Posted February 26, 2007 Hi all, isn't it possible to add russian text like this in SciTE потребность написать российский текст I'm not russian .. but i tried .. and did only return ??????????????????????? Emiel Best regards,Emiel Wieldraaijer Link to comment Share on other sites More sharing options...
Developers Jos Posted February 26, 2007 Developers Share Posted February 26, 2007 Hi all,isn't it possible to add russian text like this in SciTEпотребность написать российский текстI'm not russian .. but i tried .. and did only return ???????????????????????EmielFile/Enncoding/UTF-8 SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
DarthVega Posted February 26, 2007 Share Posted February 26, 2007 isn't it possible to add russian textI'm not russian ..I'd like to start making Japanese Auto-It scripts without learning Japanese. Link to comment Share on other sites More sharing options...
Emiel Wieldraaijer Posted February 26, 2007 Author Share Posted February 26, 2007 No man .. it's for a multilangual GUI .. someone else is translating it for me So if you can translate 120 lines of english for me in japanese .. please let me know .. @JdeB thnx but how can i activate it ? Emiel Best regards,Emiel Wieldraaijer Link to comment Share on other sites More sharing options...
James Posted February 26, 2007 Share Posted February 26, 2007 DarthVega, why do you post those posts? Your worse than me... @Emiel Wieldraaijer - You may need to have a russian font file installed, else it wont read it correctly giving you the ???'s Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ Link to comment Share on other sites More sharing options...
Developers Jos Posted February 26, 2007 Developers Share Posted February 26, 2007 @Emiel Wieldraaijer - You may need to have a russian font file installed, else it wont read it correctly giving you the ???'sSecure... Did you try what I posted and then copy/paste the posted Rusian characters ? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
James Posted February 26, 2007 Share Posted February 26, 2007 Nope. Because I'm on a non-AutoIt computer. But for a GUI russian font file is useful Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ Link to comment Share on other sites More sharing options...
Emiel Wieldraaijer Posted February 26, 2007 Author Share Posted February 26, 2007 @JdeB Sorry .. hehehehe i found it Menu File - Encoding - UTF (Stupid me) @Secure_ICT No need to install the font because .. if i didn't install it .. i could not post the question .. Best regards,Emiel Wieldraaijer Link to comment Share on other sites More sharing options...
James Posted February 26, 2007 Share Posted February 26, 2007 Ahh sorry.. I'm getting confused with myself. Sorry, I had a bad day today Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ Link to comment Share on other sites More sharing options...
MrCreatoR Posted February 26, 2007 Share Posted February 26, 2007 If you want to make a gui with support of many languages, try this (i use it for all my script that i share with my friends) :expandcollapse popup$LangFile = @ScriptDir & "\Language_ru.lng" $Message = Translation($LangFile) GUICreate($Message[1], 300, 300) GUICtrlCreateLabel($Message[2], 50, 50) GUISetState() While 1 $Msg = GUIGetMsg() Switch $msg Case -3 Exit EndSwitch WEnd Func Translation($LangFile) $TotalTranslations = 10 Global $Message[$TotalTranslations+1] $Message[1] = "This is my GUI title" $Message[2] = "This is the label text" $Message[3] = "some another text..." $Message[4] = "some another text... 1" $Message[5] = "some another text... 2" $Message[6] = "some another text... 3" $Message[7] = "some another text... 4" $Message[8] = "some another text... 5" $Message[9] = "some another text... 6" $Message[10] = "some another text... 7" If FileExists($LangFile) Then For $iLng = 1 To $TotalTranslations $ReadCurrentTransl = IniRead($LangFile, "Main Translation", "0"&$iLng, "") If $ReadCurrentTransl <> "" Then $Message[$iLng] = $ReadCurrentTransl Next EndIf Return $Message EndFuncThe file Language_ru.lng must include somthing like this:[Main Translation] 01="Это заголовок моего ГУИ" 02="Это текст надписи" 03="Другой текст..." 04="Другой текст... 1" 05="Другой текст... 2" 06="Другой текст... 3" 07="Другой текст... 4" 08="Другой текст... 5" 09="Другой текст... 6" 010="Другой текст... 7" Spoiler Using OS: Win 7 Professional, Using AutoIt Ver(s): 3.3.6.1 / 3.3.8.1 AutoIt Russian Community My Work... Spoiler Projects: ATT - Application Translate Tool {new}| BlockIt - Block files & folders {new}| SIP - Selected Image Preview {new}| SISCABMAN - SciTE Abbreviations Manager {new}| AutoIt Path Switcher | AutoIt Menu for Opera! | YouTube Download Center! | Desktop Icons Restorator | Math Tasks | KeyBoard & Mouse Cleaner | CaptureIt - Capture Images Utility | CheckFileSize ProgramUDFs: OnAutoItErrorRegister - Handle AutoIt critical errors {new}| AutoIt Syntax Highlight {new}| Opera Library! | Winamp Library | GetFolderToMenu | Custom_InputBox()! | _FileRun UDF | _CheckInput() UDF | _GUIInputSetOnlyNumbers() UDF | _FileGetValidName() UDF | _GUICtrlCreateRadioCBox UDF | _GuiCreateGrid() | _PathSplitByRegExp() | _GUICtrlListView_MoveItems - UDF | GUICtrlSetOnHover_UDF! | _ControlTab UDF! | _MouseSetOnEvent() UDF! | _ProcessListEx - UDF | GUICtrl_SetResizing - UDF! | Mod. for _IniString UDFs | _StringStripChars UDF | _ColorIsDarkShade UDF | _ColorConvertValue UDF | _GUICtrlTab_CoverBackground | CUI_App_UDF | _IncludeScripts UDF | _AutoIt3ExecuteCode | _DragList UDF | Mod. for _ListView_Progress | _ListView_SysLink | _GenerateRandomNumbers | _BlockInputEx | _IsPressedEx | OnAutoItExit Handler | _GUICtrlCreateTFLabel UDF | WinControlSetEvent UDF | Mod. for _DirGetSizeEx UDF Examples: ScreenSaver Demo - Matrix included | Gui Drag Without pause the script | _WinAttach()! | Turn Off/On Monitor | ComboBox Handler Example | Mod. for "Thinking Box" | Cool "About" Box | TasksBar Imitation Demo Like the Projects/UDFs/Examples? Please rate the topic (up-right corner of the post header: Rating ) * === My topics === * ================================================== ================================================== AutoIt is simple, subtle, elegant. © AutoIt Team Link to comment Share on other sites More sharing options...
MrCreatoR Posted February 26, 2007 Share Posted February 26, 2007 If you like to use a translation just in gui (without using the file), try this function (by amel27).expandcollapse popupMsgBox(0, "Test Rus", _Utf8ToAnsi("Русский текст")) Func _Utf8ToAnsi($utf8String) Return _Uni2Any(_Any2Uni($utf8String, 65001), 0) EndFunc Func _Any2Uni($anyString, $codePage) Local $bufSize = StringLen($anyString) * 2 Local $buf = DllStructCreate("byte[" & $bufSize & "]") Local $ret = DllCall("Kernel32.dll", "int", "MultiByteToWideChar", _ "int", $codePage, _ "int", 0, _ "str", $anyString, _ "int", StringLen($anyString), _ "ptr", DllStructGetPtr($buf), _ "int", $bufSize) Local $uniString = StringLeft(DllStructGetData($buf, 1), $ret[0] * 2) $buf = 0 Return $uniString EndFunc Func _Uni2Any($uniString, $codePage) Local $uniStringLen = StringLen($uniString) Local $bufLen = $uniStringLen * 2 Local $in = DllStructCreate("byte[" & $bufLen & "]") Local $out= DllStructCreate("char[" & $bufLen & "]") DllStructSetData($in, 1, $uniString) Local $ret = DllCall("kernel32.dll", "int", "WideCharToMultiByte", _ "int", $codePage, _ "int", 0, _ "ptr", DllStructGetPtr($in), _ "int", $uniStringLen / 2, _ "ptr", DllStructGetPtr($out), _ "int", $bufLen, _ "int", 0, _ "int", 0) Local $anyString = DllStructGetData($out, 1) $out= 0 $in = 0 Return $anyString EndFunc Spoiler Using OS: Win 7 Professional, Using AutoIt Ver(s): 3.3.6.1 / 3.3.8.1 AutoIt Russian Community My Work... Spoiler Projects: ATT - Application Translate Tool {new}| BlockIt - Block files & folders {new}| SIP - Selected Image Preview {new}| SISCABMAN - SciTE Abbreviations Manager {new}| AutoIt Path Switcher | AutoIt Menu for Opera! | YouTube Download Center! | Desktop Icons Restorator | Math Tasks | KeyBoard & Mouse Cleaner | CaptureIt - Capture Images Utility | CheckFileSize ProgramUDFs: OnAutoItErrorRegister - Handle AutoIt critical errors {new}| AutoIt Syntax Highlight {new}| Opera Library! | Winamp Library | GetFolderToMenu | Custom_InputBox()! | _FileRun UDF | _CheckInput() UDF | _GUIInputSetOnlyNumbers() UDF | _FileGetValidName() UDF | _GUICtrlCreateRadioCBox UDF | _GuiCreateGrid() | _PathSplitByRegExp() | _GUICtrlListView_MoveItems - UDF | GUICtrlSetOnHover_UDF! | _ControlTab UDF! | _MouseSetOnEvent() UDF! | _ProcessListEx - UDF | GUICtrl_SetResizing - UDF! | Mod. for _IniString UDFs | _StringStripChars UDF | _ColorIsDarkShade UDF | _ColorConvertValue UDF | _GUICtrlTab_CoverBackground | CUI_App_UDF | _IncludeScripts UDF | _AutoIt3ExecuteCode | _DragList UDF | Mod. for _ListView_Progress | _ListView_SysLink | _GenerateRandomNumbers | _BlockInputEx | _IsPressedEx | OnAutoItExit Handler | _GUICtrlCreateTFLabel UDF | WinControlSetEvent UDF | Mod. for _DirGetSizeEx UDF Examples: ScreenSaver Demo - Matrix included | Gui Drag Without pause the script | _WinAttach()! | Turn Off/On Monitor | ComboBox Handler Example | Mod. for "Thinking Box" | Cool "About" Box | TasksBar Imitation Demo Like the Projects/UDFs/Examples? Please rate the topic (up-right corner of the post header: Rating ) * === My topics === * ================================================== ================================================== AutoIt is simple, subtle, elegant. © AutoIt Team Link to comment Share on other sites More sharing options...
Emiel Wieldraaijer Posted February 26, 2007 Author Share Posted February 26, 2007 Thnx MsCreatoR .. i will take a look at it .. looks .. nice .. but i use a diffent approach .. Emiel Best regards,Emiel Wieldraaijer Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now