doestergaard Posted November 22, 2015 Posted November 22, 2015 Hi.I have just been wondering, why a font looks different from one control to another. As an example, I have a Label (top) and a Combo control (bottom). As the following image shows, there appears to be "more space" between words than there is in the label control?Can someone answer me on why this is happening? Thanks in advance!
Moderators Melba23 Posted November 23, 2015 Moderators Posted November 23, 2015 doestergaard,They look the same size to me when using the default settings:#include <GUIConstantsEx.au3> $sText = "Specify the required information" $hGUI = GUICreate("Test", 500, 500) GUICtrlCreateLabel($sText, 12, 10, 200, 20) GUICtrlCreateCombo("", 10, 30, 200, 20) GUICtrlSetData(-1, $sText, $sText) GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit EndSwitch WEndAre both the label and combo in your image using the same font size?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
doestergaard Posted November 23, 2015 Author Posted November 23, 2015 (edited) Hi Melbathx for your reply it happens in WinPE.Im setting the same font size for both the label and comboboxGUICtrlSetFont(-1, 10, 0)I will check if it still happens if im not setting a font size at all Edited November 23, 2015 by doestergaard
doestergaard Posted November 23, 2015 Author Posted November 23, 2015 Okay, so it does seem to happen only if you set a different size, here it is againCode:GUISetFont(10, 0)GUICtrlCreateLabel("Specify required information", 20, 20, 300, 24)GUICtrlCreateCombo("Specify required information", 20, 20, 300, 24, 0x0003) It is really weird
Moderators Melba23 Posted November 23, 2015 Moderators Posted November 23, 2015 doestergaard,I still get the same size text in both controls. Possibly a WinPE problem feature, but I have no ability to test that hypothesis.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
doestergaard Posted November 23, 2015 Author Posted November 23, 2015 Try set the following:GUISetFont(10, 0, "", "Euphemia") I found out to make it reoccur in Windows 7/8
Moderators Melba23 Posted November 23, 2015 Moderators Posted November 23, 2015 doestergaard,Still the same size text for me when I try that font in Win7.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
doestergaard Posted November 23, 2015 Author Posted November 23, 2015 (edited) Thats even more odd, what happens when you set it to classic style? Edited November 23, 2015 by doestergaard
Moderators Melba23 Posted November 23, 2015 Moderators Posted November 23, 2015 doestergaard,Now I see the effect - so it is not just you!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
doestergaard Posted November 23, 2015 Author Posted November 23, 2015 I was beginning to think if I was crazy Im just wondering why is happens?
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