mirror of
https://gitlab.com/sheaf/metabrush.git
synced 2024-11-27 09:24:08 +00:00
fix styling on dialog windows
This commit is contained in:
parent
c3bcce58a7
commit
2ee0cbbfc0
|
@ -225,6 +225,7 @@ tooltip {
|
||||||
border-radius: 6px;
|
border-radius: 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* dialog button */
|
||||||
.dialogButton {
|
.dialogButton {
|
||||||
background-color: rgb(72,70,61);
|
background-color: rgb(72,70,61);
|
||||||
border: 1px solid black;
|
border: 1px solid black;
|
||||||
|
@ -278,7 +279,10 @@ tooltip {
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Submenus without separators */
|
/* Submenus without separators */
|
||||||
.menu item > popover > contents > stack > box > box > modelbutton {
|
.menu item > popover > contents > stack > box > box > modelbutton,
|
||||||
|
/* Submenus with separators */
|
||||||
|
.menu item > popover > contents > stack > box > box > box > box > modelbutton
|
||||||
|
{
|
||||||
background-color: rgb(41, 40, 40);
|
background-color: rgb(41, 40, 40);
|
||||||
color: rgb(72,70,61);
|
color: rgb(72,70,61);
|
||||||
border-top: 0px;
|
border-top: 0px;
|
||||||
|
@ -286,14 +290,6 @@ tooltip {
|
||||||
padding: 2px 10px 6px 10px;
|
padding: 2px 10px 6px 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Submenus with separators */
|
|
||||||
.menu item > popover > contents > stack > box > box > box > box > modelbutton {
|
|
||||||
background-color: rgb(41, 40, 40);
|
|
||||||
color: rgb(72,70,61);
|
|
||||||
border-top: 0px;
|
|
||||||
border-left: 2px solid rgb(41, 40, 40);
|
|
||||||
padding: 2px 10px 6px 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.menu item > popover > contents > stack > box > box > box > separator,
|
.menu item > popover > contents > stack > box > box > box > separator,
|
||||||
.menu item > popover > contents > stack > box > box > box > separator :hover {
|
.menu item > popover > contents > stack > box > box > box > separator :hover {
|
||||||
|
@ -302,7 +298,6 @@ tooltip {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
.accelLabel {
|
.accelLabel {
|
||||||
padding: 2px 8px 2px 0px;
|
padding: 2px 8px 2px 0px;
|
||||||
}
|
}
|
||||||
|
|
|
@ -243,8 +243,8 @@ warningDialog window filePath errMess = do
|
||||||
GTK.setWindowDecorated dialog False
|
GTK.setWindowDecorated dialog False
|
||||||
GTK.windowSetTransientFor dialog ( Just window )
|
GTK.windowSetTransientFor dialog ( Just window )
|
||||||
GTK.windowSetModal dialog True
|
GTK.windowSetModal dialog True
|
||||||
widgetAddClasses dialog [ "bg", "plain", "text", "dialog" ]
|
widgetAddClasses dialog [ "metabrush", "bg", "plain", "text", "dialog" ]
|
||||||
closeButton <- GTK.dialogAddButton dialog "OK" 1
|
closeButton <- GTK.dialogAddButton dialog "OK" 1
|
||||||
widgetAddClass closeButton "dialogButton"
|
widgetAddClass closeButton "dialogButton"
|
||||||
GTK.widgetShow dialog
|
GTK.widgetShow dialog
|
||||||
void $ GTK.afterDialogResponse dialog \ _ -> do
|
void $ GTK.afterDialogResponse dialog \ _ -> do
|
||||||
|
@ -396,12 +396,13 @@ instance HandleAction Close where
|
||||||
GTK.setWindowDecorated dialog False
|
GTK.setWindowDecorated dialog False
|
||||||
GTK.windowSetTransientFor dialog ( Just window )
|
GTK.windowSetTransientFor dialog ( Just window )
|
||||||
GTK.windowSetModal dialog True
|
GTK.windowSetModal dialog True
|
||||||
widgetAddClasses dialog [ "bg", "plain", "text", "dialog" ]
|
widgetAddClasses dialog [ "metabrush", "bg", "plain", "text", "dialog" ]
|
||||||
closeButton <- GTK.dialogAddButton dialog "Close" JustClose
|
closeButton <- GTK.dialogAddButton dialog "Close" JustClose
|
||||||
saveButton <- GTK.dialogAddButton dialog "Save and close" SaveAndClose
|
saveButton <- GTK.dialogAddButton dialog "Save and close" SaveAndClose
|
||||||
cancelButton <- GTK.dialogAddButton dialog "Cancel" CancelClose
|
cancelButton <- GTK.dialogAddButton dialog "Cancel" CancelClose
|
||||||
GTK.dialogSetDefaultResponse dialog 1
|
GTK.dialogSetDefaultResponse dialog JustClose
|
||||||
for_ [ closeButton, saveButton, cancelButton ] \ button -> widgetAddClass button "dialogButton"
|
for_ [ closeButton, saveButton, cancelButton ]
|
||||||
|
( `widgetAddClass` "dialogButton" )
|
||||||
GTK.widgetShow dialog
|
GTK.widgetShow dialog
|
||||||
void $ GTK.onDialogResponse dialog \ choice -> do
|
void $ GTK.onDialogResponse dialog \ choice -> do
|
||||||
case choice of
|
case choice of
|
||||||
|
|
Loading…
Reference in a new issue