mirror of
https://gitlab.com/sheaf/metabrush.git
synced 2024-11-06 15:23:37 +00:00
42 lines
831 B
Plaintext
42 lines
831 B
Plaintext
|
module MetaBrush.UI.FileBar
|
||
|
( FileBar(..), createFileBar, newFileTab
|
||
|
, TabLocation(..)
|
||
|
)
|
||
|
where
|
||
|
|
||
|
-- gi-gtk
|
||
|
import qualified GI.Gtk as GTK
|
||
|
|
||
|
-- MetaBrush
|
||
|
import {-# SOURCE #-} MetaBrush.Context
|
||
|
( Variables )
|
||
|
import MetaBrush.Document
|
||
|
( Document )
|
||
|
import {-# SOURCE #-} MetaBrush.UI.InfoBar
|
||
|
( InfoBar )
|
||
|
|
||
|
--------------------------------------------------------------------------------
|
||
|
|
||
|
data FileBar
|
||
|
= FileBar
|
||
|
{ fileBarBox :: !GTK.Box
|
||
|
, fileTabsBox :: !GTK.Box
|
||
|
, fileBarPhantomRadioButton :: !GTK.RadioButton
|
||
|
}
|
||
|
|
||
|
data TabLocation
|
||
|
= AfterCurrentTab
|
||
|
| LastTab
|
||
|
|
||
|
createFileBar
|
||
|
:: Variables
|
||
|
-> GTK.Window -> GTK.Label -> GTK.DrawingArea -> InfoBar
|
||
|
-> IO FileBar
|
||
|
|
||
|
newFileTab
|
||
|
:: Variables
|
||
|
-> GTK.Window -> GTK.Label -> FileBar -> GTK.DrawingArea -> InfoBar
|
||
|
-> Maybe Document
|
||
|
-> TabLocation
|
||
|
-> IO ()
|