name15 Posted February 1, 2010 Share Posted February 1, 2010 how to change font writing in window and how to detected which font use in window Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted February 1, 2010 Moderators Share Posted February 1, 2010 name15,You set a font for a control by using GUICtrlSetFont (or GUISetFont if you want all controls to use the same font).Getting the font from a control is more difficult, but PsaltyDS produced a script to do it here.M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
name15 Posted February 1, 2010 Author Share Posted February 1, 2010 (edited) you get wrong idea detected type of font (like french or Germany) in window whiteout using tool course some time user use shortcut (shift + Alt) to change writing language in window like in Notepad Edited February 1, 2010 by name15 Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted February 1, 2010 Moderators Share Posted February 1, 2010 (edited) name15,If you want to distinguish between LANGUAGES (which is what French and German are) than there is nothing in AutoIt to help.The Google Language API might be of help - you can find out about it here.M23Language:English = the words used to speak or write.French = les mots utilises pour parler/ecrireGerman = die Wörter zu sprechen oder zu schreibenFont = the variable shape of the letters used to write the words:This is CourierThis is TahomaThis is Comic Sans MSEdit following your edit:some time user use shortcut (shift + Alt) to change writing language in window like in NotepadThis is a Windows function which changes the keyboard layout - it has nothing to do with language. If you want to use AutoIt to do this, look at Send in the Help file.M23 Edited February 1, 2010 by Melba23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
name15 Posted February 1, 2010 Author Share Posted February 1, 2010 thank to make everything clear but all i want just detected keyboard layout i have ready read help in send but i don't get what i want Link to comment Share on other sites More sharing options...
Yashied Posted February 1, 2010 Share Posted February 1, 2010 (edited) thank to make everything clear but all i want just detected keyboard layout i have ready read help in send but i don't get what i want Look at _WinAPI_GetKeyboardLayout() and _WinAPI_SetKeyboardLayout() from the WinAPIEx.au3 library. #Include <Array.au3> #Include <GUIConstantsEx.au3> #Include <WinAPIEx.au3> Opt('MustDeclareVars', 1) Global $hForm, $Msg, $Button, $Index, $Label, $Layout, $List = _WinAPI_GetKeyboardLayoutList() Global $hAutoIt = WinGetHandle(AutoItWinGetTitle()) $hForm = GUICreate('MyGUI', 250, 120) $Layout = _WinAPI_GetKeyboardLayout($hAutoIt) $Index = _ArraySearch($List, $Layout, 1) $Label = GUICtrlCreateLabel('0x' & Hex($Layout, 4), 20, 34, 210, 30, 0x01) GUICtrlSetFont(-1, 18, 800, 0, 'Tahoma') $Button = GUICtrlCreateButton('Next Layout', 75, 90, 100, 23) GUISetState() While 1 $Msg = GUIGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE ExitLoop Case $Button $Index += 1 If $Index > $List[0] Then $Index = 1 EndIf _WinAPI_SetKeyboardLayout($hAutoIt, $List[$Index]) GUICtrlSetData($Label, '0x' & Hex($List[$Index], 4)) EndSwitch WEnd Edited February 1, 2010 by Yashied My UDFs: iKey | FTP Uploader | Battery Checker | Boot Manager | Font Viewer | UDF Keyword Manager | Run Dialog Replacement | USBProtect | 3D Axis | Calculator | Sleep | iSwitcher | TM | NetHelper | File Types Manager | Control Viewer | SynFolders | DLL Helper Animated Tray Icons UDF Library | Hotkeys UDF Library | Hotkeys Input Control UDF Library | Caret Shape UDF Library | Context Help UDF Library | Most Recently Used List UDF Library | Icons UDF Library | FTP UDF Library | Script Communications UDF Library | Color Chooser UDF Library | Color Picker Control UDF Library | IPHelper (Vista/7) UDF Library | WinAPI Extended UDF Library | WinAPIVhd UDF Library | Icon Chooser UDF Library | Copy UDF Library | Restart UDF Library | Event Log UDF Library | NotifyBox UDF Library | Pop-up Windows UDF Library | TVExplorer UDF Library | GuiHotKey UDF Library | GuiSysLink UDF Library | Package UDF Library | Skin UDF Library | AITray UDF Library | RDC UDF Library Appropriate path | Button text color | Gaussian random numbers | Header's styles (Vista/7) | ICON resource enumeration | Menu & INI | Tabbed string size | Tab's skin | Pop-up circular menu | Progress Bar without animation (Vista/7) | Registry export | Registry path jumping | Unique hardware ID | Windows alignment More... Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted February 2, 2010 Moderators Share Posted February 2, 2010 name15, Glad we got there in the end! M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
name15 Posted February 2, 2010 Author Share Posted February 2, 2010 how can i use _WinAPI_SetKeyboardLayout Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted February 2, 2010 Moderators Share Posted February 2, 2010 name15,Look at Yashied's code above - it shows how to use both _WinAPI_GetKeyboardLayout and _WinAPI_SetKeyboardLayout. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
name15 Posted February 3, 2010 Author Share Posted February 3, 2010 thank for all try help me but i change code in script to use it to control writing language in notepad but writing language doesn't change to french #Include <Array.au3> #Include <GUIConstantsEx.au3> #Include <WinAPIEx.au3> Opt('MustDeclareVars', 1) run("Notepad.exe") Global $hForm, $Msg, $Button, $Index, $Label, $Layout, $List = _WinAPI_GetKeyboardLayoutList() Global $hAutoIt = WinGetHandle("[CLASS:Notepad]","") $hForm = GUICreate('MyGUI', 250, 120) $Layout = _WinAPI_GetKeyboardLayout($hAutoIt) $Index = _ArraySearch($List, $Layout, 1) $Label = GUICtrlCreateLabel('0x' & Hex($Layout, 4), 20, 34, 210, 30, 0x01) GUICtrlSetFont(-1, 18, 800, 0, 'Tahoma') $Button = GUICtrlCreateButton('Next Layout', 75, 90, 100, 23) GUISetState() While 1 $Msg = GUIGetMsg() Switch $Msg Case $GUI_EVENT_CLOSE ExitLoop Case $Button $Index += 1 If $Index > $List[0] Then $Index = 1 EndIf _WinAPI_SetKeyboardLayout($hAutoIt, $List[$Index]) GUICtrlSetData($Label, '0x' & Hex($List[$Index], 4)) EndSwitch WEnd Link to comment Share on other sites More sharing options...
Moderators Melba23 Posted February 3, 2010 Moderators Share Posted February 3, 2010 name15,Those functions just set the keyboard layout - for example a French keyboard has accented characters on the number keys and an AZERTY layout. They do NOT change the language you use - it is up to you to type in the French words that these letters spell!An example: Je tape ces mots francais avec un clavier anglais. I am typing these French words with an English keyboard.As you can see, the language has nothing to do with the keyboard layout! M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to comment Share on other sites More sharing options...
name15 Posted February 16, 2010 Author Share Posted February 16, 2010 thank you for explain all these think but there any way to change the language 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