AutoByte Posted Friday at 03:25 AM Share Posted Friday at 03:25 AM Hi, How do I add a white area and a horizontal line to a form? I can't find the controls. This is a gooey library GUI in Python. Link to comment Share on other sites More sharing options...
Solution argumentum Posted Friday at 03:57 AM Solution Share Posted Friday at 03:57 AM (edited) #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <TabConstants.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= Local $iW = 600, $iH = 200 $Form1 = GUICreate("Form1", $iW, $iH) $Tab1 = GUICtrlCreateTab(0, 0, $iW, 100) GUICtrlCreateTabItem("") $Label1 = GUICtrlCreateLabel("Label1", 10, 150, $iW - 20, 1, -1, $WS_EX_STATICEDGE) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Doesn't look that good in all dark mode: ( but no one has those for now ) Edited Friday at 04:03 AM by argumentum Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting. Link to comment Share on other sites More sharing options...
argumentum Posted Friday at 04:14 AM Share Posted Friday at 04:14 AM #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <TabConstants.au3> #include <WindowsConstants.au3> Local $iW = 600, $iH = 200 $Form1 = GUICreate("Form1", $iW, $iH) $Tab1 = GUICtrlCreateTab(-10, -10, $iW + 20, 100) ; over extend GUICtrlCreateTabItem("") $Label1 = GUICtrlCreateLabel("Label1", 10, 150, $iW - 20, 3, -1, $WS_EX_STATICEDGE) ; thicker separator ? GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE GUIDelete() Exit EndSwitch WEnd ...be creative. Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting. Link to comment Share on other sites More sharing options...
AutoByte Posted Friday at 04:39 PM Author Share Posted Friday at 04:39 PM 12 hours ago, argumentum said: #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <TabConstants.au3> #include <WindowsConstants.au3> Local $iW = 600, $iH = 200 $Form1 = GUICreate("Form1", $iW, $iH) $Tab1 = GUICtrlCreateTab(-10, -10, $iW + 20, 100) ; over extend GUICtrlCreateTabItem("") $Label1 = GUICtrlCreateLabel("Label1", 10, 150, $iW - 20, 3, -1, $WS_EX_STATICEDGE) ; thicker separator ? GUISetState(@SW_SHOW) While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE GUIDelete() Exit EndSwitch WEnd ...be creative. Hi, Thank you for help, but when I click [Koda] - [File] - [Import] - [Import Autoit GUI] - [Paste code above] - [Process], it has an error like this, How to resolve it? Link to comment Share on other sites More sharing options...
argumentum Posted Friday at 05:03 PM Share Posted Friday at 05:03 PM I use Koda just for the declarations. Say I need a GUI and a button. I open Koda and add a button. #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 494, 303, 192, 124, BitOR($GUI_SS_DEFAULT_GUI,$WS_MAXIMIZEBOX,$WS_SIZEBOX,$WS_THICKFRAME,$WS_TABSTOP), BitOR($WS_EX_TOPMOST,$WS_EX_WINDOWEDGE)) $Button1 = GUICtrlCreateButton("Button1", 128, 120, 75, 25) GUICtrlSetResizing(-1, $GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Copy that to the script and do the rest manually. #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= Local $sTitle = "Form1", $iW = 400, $iH = 200 $Form1 = GUICreate($sTitle, $iW, $iH, -1, -1, BitOR($GUI_SS_DEFAULT_GUI,$WS_MAXIMIZEBOX,$WS_SIZEBOX,$WS_THICKFRAME,$WS_TABSTOP), BitOR($WS_EX_TOPMOST,$WS_EX_WINDOWEDGE)) Local $Button0, $Button1, $Button2, $Button3 For $n = 0 To 3 Assign("Button" & $n, GUICtrlCreateButton("Button" & $n + 1, 10 + (95 * $n), 10, 75, 25)) GUICtrlSetResizing(-1, $GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT) Next GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### <<< no longer importable While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE GUIDelete() Exit EndSwitch WEnd and that will not import. Hence the "be creative" Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting. Link to comment Share on other sites More sharing options...
AutoByte Posted yesterday at 01:40 AM Author Share Posted yesterday at 01:40 AM 8 hours ago, argumentum said: I use Koda just for the declarations. Say I need a GUI and a button. I open Koda and add a button. #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 494, 303, 192, 124, BitOR($GUI_SS_DEFAULT_GUI,$WS_MAXIMIZEBOX,$WS_SIZEBOX,$WS_THICKFRAME,$WS_TABSTOP), BitOR($WS_EX_TOPMOST,$WS_EX_WINDOWEDGE)) $Button1 = GUICtrlCreateButton("Button1", 128, 120, 75, 25) GUICtrlSetResizing(-1, $GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Copy that to the script and do the rest manually. #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= Local $sTitle = "Form1", $iW = 400, $iH = 200 $Form1 = GUICreate($sTitle, $iW, $iH, -1, -1, BitOR($GUI_SS_DEFAULT_GUI,$WS_MAXIMIZEBOX,$WS_SIZEBOX,$WS_THICKFRAME,$WS_TABSTOP), BitOR($WS_EX_TOPMOST,$WS_EX_WINDOWEDGE)) Local $Button0, $Button1, $Button2, $Button3 For $n = 0 To 3 Assign("Button" & $n, GUICtrlCreateButton("Button" & $n + 1, 10 + (95 * $n), 10, 75, 25)) GUICtrlSetResizing(-1, $GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT) Next GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### <<< no longer importable While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE GUIDelete() Exit EndSwitch WEnd and that will not import. Hence the "be creative" Thank you. argumentum 1 Link to comment Share on other sites More sharing options...
AutoByte Posted 9 hours ago Author Share Posted 9 hours ago On 11/23/2024 at 1:03 AM, argumentum said: I use Koda just for the declarations. Say I need a GUI and a button. I open Koda and add a button. #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 494, 303, 192, 124, BitOR($GUI_SS_DEFAULT_GUI,$WS_MAXIMIZEBOX,$WS_SIZEBOX,$WS_THICKFRAME,$WS_TABSTOP), BitOR($WS_EX_TOPMOST,$WS_EX_WINDOWEDGE)) $Button1 = GUICtrlCreateButton("Button1", 128, 120, 75, 25) GUICtrlSetResizing(-1, $GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd Copy that to the script and do the rest manually. #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #Region ### START Koda GUI section ### Form= Local $sTitle = "Form1", $iW = 400, $iH = 200 $Form1 = GUICreate($sTitle, $iW, $iH, -1, -1, BitOR($GUI_SS_DEFAULT_GUI,$WS_MAXIMIZEBOX,$WS_SIZEBOX,$WS_THICKFRAME,$WS_TABSTOP), BitOR($WS_EX_TOPMOST,$WS_EX_WINDOWEDGE)) Local $Button0, $Button1, $Button2, $Button3 For $n = 0 To 3 Assign("Button" & $n, GUICtrlCreateButton("Button" & $n + 1, 10 + (95 * $n), 10, 75, 25)) GUICtrlSetResizing(-1, $GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT) Next GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### <<< no longer importable While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE GUIDelete() Exit EndSwitch WEnd and that will not import. Hence the "be creative" Hi argumentum, Excuse me, but the controls I've added always have a gap between them and the menu that I cannot eliminate. If I want to have no gap at all, is there a way to remove it? Link to comment Share on other sites More sharing options...
argumentum Posted 4 hours ago Share Posted 4 hours ago (edited) Not that I know of. PS: You may want to select the folder where the dicom files are at, because you're likely to convert all the files for the study. Otherwise you're gonna make the user select each file and would be a pain for the person selecting a bunch of files with numbers as name and is just non-sense for the user. If you're going to go with each file, pull the header data and give the user: Patient, study date, study Description, series Description and image number, and put it in a listview, so that it makes sense for the user. Cheers PS2: You don't have to quote the prior post. I can read the thread Edited 4 hours ago by argumentum advise ? Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting. 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