Search the Community
Showing results for tags 'style'.
-
How can you select the specific style of a font with multiple * .otf files? The font in question has several files: Thin Thin Italic Extra-Light Extra-Light Italic Light Light Italic Regular Regular Italic Medium Medium Italic Semi-Bold Semi-Bold Italic Bold Bold Italic Extra-Bold Extra-Bold Italic Black Black Italic But after doing several tests I can recall the font like this, without being able to specify the precise style: Local $hFamily = _GDIPlus_FontFamilyCreate("Poppins") ; Local $hFont = _GDIPlus_FontCreate($hFamily, 95, 1+2, 3) ; Example I cannot therefore select "Poppins Black Italic" but only "Poppins" Thank you
-
Hi so i ran into a Problem i didn't expect to get stuck on. It sounds simple (and probably is) but i can't seem to get it to work So i created a Combobox and filled it with some things from an array which worked fine. $combobox = GUICtrlCreateCombo($list[0], 160, 200, 265, 25, BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL)) GuiCtrlSetData($list, "|" & _ArrayToString($list,Default,1),$list[2]) GUICtrlSetFont(-1, 9, 400, 0, "Arial") Now i want to change the style of the combobox from $CBS_DROPDOWN to $CBS_DROPDOWNLIST via a checkbox. $Checkbox1 = GUICtrlCreateCheckbox("Checkbox1", 160, 96, 105, 25) Case $Checkbox1 If GUICtrlRead($Checkbox1) = $GUI_CHECKED Then Call ("Read_only") Else Call ("Edit") Endif Func Read_only() GUICtrlSetStyle ($Combobox1,something to change it to $CBS_DROPDOWNLIST) EndFunc Func Edit() GUICtrlSetStyle ($Combobox1,something to change it to $CBS_DROPDOW) EndFunc I tried using $CBS_DROPDOWN and $CBS_DROPDOWNLIST but it simply does nothing. I also tried $ES_READONLY which kinda worked, it changed the combobox so i couldn't change the input via dropdown anymore but i could still type in it via keyboard (which i dont want). It's essential that its Editable but once the checkbox is checked the combobox becomes readonly so you can't type in it anymore but you can still choose between the items in the list. (It does not have to save your current input if you write something in it and then check the Checkbox it would be best if it would simpy jump back to the first item in the list) Im sure this is a simple thing but after long google search im tired of my stupidity can someone give me a push in the right direction?
-
Hello Dear Sirs, I have a question please About UPDown ctrl Where I want to adjust its format For example, I want to create a window to set the clock like the window in the system Can this be done? here's the example ______ #include <WindowsConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <UpDownConstants.au3> goto() func Goto() local $wGoto = GUICreate("go to spissific position", 250, 180, @DesktopWidth / 2 - 192, @DesktopHeight / 2 - 235, -1) GUICtrlCreateLabel("please write a corect position to go to it", 50, 10, 220, 20) GUICtrlCreateLabel("hours", 0, 80, 100, 30) local $Inp1 = GUICtrlCreateInput("00", 0, 90, 100, 20, $ES_NUMBER + $WS_TABSTOP) GUICtrlCreateUpdown($Inp1, $UDS_ARROWKEYS) GUICtrlSetLimit(-1, 23, 0) GUICtrlCreateLabel("minuts", 110, 80, 100, 30) local $Inp2 = GUICtrlCreateInput("00", 110, 90, 100, 20, $ES_NUMBER + $WS_TABSTOP) GUICtrlCreateUpdown($Inp2, $UDS_ARROWKEYS) GUICtrlSetLimit(-1, 60, 0) GUICtrlCreateLabel("seconds", 220, 80, 100, 30) local $Inp3 = GUICtrlCreateInput("00", 220, 90, 100, 20, $ES_NUMBER + $WS_TABSTOP) GUICtrlCreateUpdown($Inp3, $UDS_ARROWKEYS) GUICtrlSetLimit(-1, 60, 0) local $Ok = GUICtrlCreateButton("&ok", 0, 150, 50, 30, 0x01) local $cancel = GUICtrlCreateButton("&cancel", 200, 150, 50, 30) GUISetState(@sw_show, $WgoTo) while 1 switch GUIGetMSG() case $GUI_Event_Close, $cancel exit case $OK local $read1 = GUICtrlRead($inp1) if $read1 >= 1 then $Read1 = ($Read1*60)*60 local $read2 = GUICtrlRead($inp2) if $read2 >= 1 then $Read2 = $Read2*60 local $read3 = GUICtrlRead($inp3) GUIDelete($WgoTo) Return $read1+$read2+$read3 exit endSwitch Wend EndFunc ________ What I need is to be the contents of the inputs as follows when i change the value of the UPDown CTRL 00 01 02 03 ...
-
Hello, dears. First I apologise to you for the stupid question I'm going to ask. is the default style for Windows created using AutoIt a dialog box style? I decided to ask this question Because I am using a screen reader If i open any program that is designed using autoit, the screen reader read for example, test dialog but If i open any other program, for example goldwave, it read goldwav only without a word dialog Is there a solution to this The code i used to create the window is: $hGUI = GUICreate(str("title"), 500, 420, -1, -1, BitOr($WS_MAXIMIZEBOX, $WS_MINIMIZEBOX, $WS_SIZEBOX, $WS_SYSMENU, $WS_CAPTION), BitOr($WS_EX_ACCEPTFILES,$WS_EX_LAYERED,$WS_EX_CLIENTEDGE,$WS_EX_STATICEDGE)) I hope to find a solution to this problem please Accept my greetings, and thank you very much.
-
Good morning I was looking around the forum if there were some customizable solutions about creating a PDF from "0" to something like a report... What I'd like to do is something with a header ( 2 logos and a title ), with a table which contains data read from a file At the moment, I was working with HTML, since I know it and it's very simple to do a table with some data inside... But know, I'm a bit stuck about the exporting the HTML page to PDF... And, here too, if someone knows how to do it, please, I'm here listening Thanks guys
-
Tell me, please, why in the application of different styles($SS_BLACKFRAME, $SS_BLACKRECT, etc.) of frames stops working function Msg(). And why in the application of certain frame styles($SS_BLACKFRAME) do not even picture displayed? #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <StaticConstants.au3> Opt("GUIOnEventMode", 1) Example() Func Example() GUICreate("My GUI picture", 350, 300, -1, -1) ; will create a dialog box that when displayed is centered GUISetOnEvent($GUI_EVENT_CLOSE,"Quit") $idPic = GUICtrlCreatePic("D:\Program Files\AutoIt3\Examples\GUI\mslogo.jpg", 50, 50, 200, 50, $SS_SUNKEN) GUICtrlSetOnEvent(-1,"Msg") GUISetState(@SW_SHOW) ; Loop until the user exits. While 1 WEnd EndFunc ;==>Example Func Msg() MsgBox(0,0,0) EndFunc Func Quit() Exit EndFunc
- 16 replies
-
- guictrlcreatepic
- guictrlsetonevent
-
(and 1 more)
Tagged with:
-
Please tell me, who knows how to apply and cancel styles in RTF? The following code does not work: #include <GuiRichEdit.au3> #include <WindowsConstants.au3> $hGUI = GUICreate("RichEdit Style", 500, 500, -1, -1) $hRichEdit = _GUICtrlRichEdit_Create($hGui, "Test", 20,40,460,400) GUISetState(@SW_SHOW, $hGUI) Sleep(3000) GUICtrlSetStyle($hRichEdit, $ES_RIGHT) Sleep(3000) GUICtrlSetStyle($hRichEdit, -1) Sleep(3000) Thanks!
-
Hello, A small tool from me opens certain text files and displays the content in some sort of "preview", by chance a user selected a file that is "large" ~ 10 MB. (of course my test files are small enough :-) ) But this takes very long (~ 4 secs on that pc), first I thought it is reading the file but I stripped it down to the edit control update. I extracted the issue to a sample au3 attached and a sample large file. The log lines are from the dummy1.au3. (11:19:40.352) - -->Line0017): openfile (11:19:40.461) - -->Line0021): closefile (11:19:40.461) - -->Line0022): update ctrlfile start (11:19:45.581) - -->Line0024): update ctrlfile done I see that reading the file is fast enough( 109ms) , but the edit control update takes long (5120 ms). Question: Based on the dummy1, is there a chance to speed up? I'm open to accept also other advices, the purpose of the edit is just to display the file and allow scrolling. I thought about reading only a certain amount of lines and if the user scrolls read the rest.....or so. Or is it just like this by design. Or what is more likely, what is wrong on my code? Of course my real app displays now in the mean time something like "Loading...." but that does not solve it. And yes, I used FS. Found something similar, but the thread was drifting apart from the issue without solving it... dummy1.au3 largetextfile.txt
- 13 replies
-
- edit ctrl slow
- update autoscroll
-
(and 1 more)
Tagged with:
-
I have the following code which is meant to change the "extended style" of all the GUIs in the project, but it doesn't want to take. I thought I followed the help file, when the tray icon is checked, leave the standard styles as their defaults and add $WS_EX_TOPMOST to the extended styles, and when unchecked, set the styles back to what the GUI was originally created with. Please help: #Region ;**** Directives created by AutoIt3Wrapper_GUI **** #AutoIt3Wrapper_Res_SaveSource=y #AutoIt3Wrapper_Res_requestedExecutionLevel=requireAdministrator #AutoIt3Wrapper_Add_Constants=n #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI **** #cs ---------------------------------------------------------------------------- AutoIt Version: 3.3.15.0 (Beta) Author: myName Script Function: Template AutoIt script. #ce ---------------------------------------------------------------------------- ; Script Start - Add your code below here #include <GUIConstantsEx.au3> ; *** End added by AutoIt3Wrapper *** ; *** Start added by AutoIt3Wrapper *** #include <FontConstants.au3> ; *** End added by AutoIt3Wrapper *** ; *** Start added by AutoIt3Wrapper *** #include <ListViewConstants.au3> #include <WindowsConstants.au3> ; *** End added by AutoIt3Wrapper *** ; *** Start added by AutoIt3Wrapper *** #include <GUIConstants.au3> ; *** End added by AutoIt3Wrapper *** ; *** Start added by AutoIt3Wrapper *** #include <AutoItConstants.au3> #include <ListBoxConstants.au3> #include <MsgBoxConstants.au3> #include <Array.au3> #include <GuiListView.au3> #include <FileConstants.au3> #include <StaticConstants.au3> #include <ButtonConstants.au3> #include <ComboConstants.au3> #include <Constants.au3> #include <Misc.au3> #include <GuiButton.au3> #include <MsgBoxConstants.au3> #include <GuiListBox.au3> #include <GuiListView.au3> #include <Crypt.au3> Const $path = @AppDataDir & "\filler" Opt ( "TrayMenuMode", 1 ) $nonote = False $TrayMenu = TrayCreateMenu ( "Settings" ) $settings1 = TrayCreateItem ( "Turn off notifications", $TrayMenu ) TrayItemSetState ( -1, Int ( IniRead ( $path & "\infostore.ini", "Tray Settings", "No Notifications", "68" ) ) ) $settings2 = TrayCreateItem ( "Keep Window on top", $TrayMenu ) TrayItemSetState ( -1, Int ( IniRead ( $path & "\infostore.ini", "Tray Settings", "On top", "68" ) ) ) $Form1_1 = GUICreate("Form filler", 701, 659, 317, 125, BitOR($GUI_SS_DEFAULT_GUI, $WS_MAXIMIZEBOX, $WS_SIZEBOX, $WS_THICKFRAME, $WS_TABSTOP)) If TrayItemGetState ( $settings2 ) = 65 Then GUISetStyle ( -1, $WS_EX_TOPMOST ) EndIf GUISetState(@SW_SHOW, $Form1_1) While 1 $tmsg = TrayGetMsg () $nMsg = GUIGetMsg() Switch $tmsg Case $TrayMenu Case $settings1 #Region --- CodeWizard generated code Start --- ;MsgBox features: Title=Yes, Text=Yes, Buttons=OK, Icon=None MsgBox($MB_OK,"State",TrayItemGetState ($settings1)) #EndRegion --- CodeWizard generated code End --- If TrayItemGetState ( $settings1 ) = 65 Then IniWrite ( $path & "\infostore.ini", "Tray Settings", "No Notifications", "65" ) ElseIf TrayItemGetState ( $settings1 ) = 68 Then IniWrite ( $path & "\infostore.ini", "Tray Settings", "No Notifications", "68" ) Else EndIf Case $settings2 If TrayItemGetState ( $settings2 ) = 65 Then IniWrite ( $path & "\infostore.ini", "Tray Settings", "On top", "65" ) GUISetStyle ( -1, $WS_EX_TOPMOST, $Form1_1 ) ElseIf TrayItemGetState ( $settings2 ) = 68 Then IniWrite ( $path & "\infostore.ini", "Tray Settings", "On top", "68" ) GUISetStyle ( BitOR($GUI_SS_DEFAULT_GUI, $WS_MAXIMIZEBOX, $WS_SIZEBOX, $WS_THICKFRAME, $WS_TABSTOP), 0, $Form1_1 ) Else EndIf EndSwitch Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd While this is a snippet of the code, it is the portion which illustrates my issue and can be compiled, so have at it.
-
$ListLHT = GUICtrlCreateList("", 8, 152, 664, 279,BitOR($WS_GROUP,$WS_BORDER,$WS_VSCROLL,$WS_HSCROLL)) Hi, code works, but not documented. Its not in the Help file, but HSCROLL works for List 3.3.12.0 If I am wrong, please point me in the right direction. Have a nice day now
- 8 replies
-
- $ws_hscroll
- helpfile
-
(and 2 more)
Tagged with:
-
How can I programatically find the styles of all the sentences on a Microsoft Word document? I tried this code but it didn't work: #include <Word.au3> Global $oWord, $oDoc $oWord = _Word_Create() $oDoc = _Word_DocGet($oWord, 1) Local $sCount = $oDoc.Sentences.Count For $i = 0 To $sCount - 1 Local $oRange = _Word_DocRangeSet($oDoc, -1, $wdSentence, $i, $wdSentence, 1) ConsoleWrite("The style of this sentence is: " & $oRange.Style & @LF) Next
-
Hi, I'm trying to setting ( in the example remove ) the style from a extenal Windows but not work So my question are: - Why not work? - The return value of GetWindowLong is: + old style: 136 + new style: 128 How i can know if 136-128 is equal to which style?
-
Hello everyone. I have run into a problem that is somewhere along the lines of GUISetStyle() does not really function as it should. In one of my programs, I had $WS_EX_TOPMOST as the extended style of the GUI. When I added functionality for a tray item to change whether or not the GUI had this style applied, I found that GUISetStyle did not do anything. Maybe I did something wrong? But then, I set up a test program and found that if I created the GUI without setting the style, and then using GUISetStyle() right afterwards, nothing happened (the GUI did not stay on top of the other windows). Here is the test program that I used. Did I use the function wrong, or why is the style not being set? Thanks. Here is the program: #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <Constants.au3> Opt("TrayMenuMode", 1) Opt("TrayOnEventMode", 1) TrayCreateItem("Exit") TrayItemSetOnEvent(-1, "trayExit") TrayCreateItem("Keep GUI On Top of Other Windows") TrayItemSetState(-1, $TRAY_CHECKED) TrayItemSetOnEvent(-1, "trayKeepGUIOnTop") Global $boolKeepGUIOnTop = True Global $hForm = GUICreate("Lark Autoclicker", 580, 550) ConsoleWrite(GUISetStyle(BitOR($WS_MINIMIZEBOX, $WS_CAPTION, $WS_POPUP, $WS_SYSMENU), $WS_EX_TOPMOST, $hForm) & @CRLF & @CRLF) GUISetState() Do Until GUIGetMsg() = -3 Func trayKeepGUIOnTop() If $boolKeepGUIOnTop Then; if its true then set it to false and get rid of the style of the GUI ConsoleWrite("true" & @CRLF) $boolKeepGUIOnTop = False ConsoleWrite(GUISetStyle(BitOR($WS_MINIMIZEBOX, $WS_CAPTION, $WS_POPUP, $WS_SYSMENU), 0) & @CRLF & @CRLF); set the GUI to its default style Else ConsoleWrite("false" & @CRLF) $boolKeepGUIOnTop = True; its false so set it to true GUISetStyle(-1, $WS_EX_TOPMOST); set the GUI to stay on top EndIf EndFunc Func trayExit(); for the tray item "Exit" Exit EndFunc
- 2 replies
-
- GUISetStyle
- style
-
(and 2 more)
Tagged with: