|
From: Andy S. <And...@co...> - 2010-05-24 03:44:36
|
diffing dir...
Sun May 23 23:43:49 EDT 2010 Andy Stewart <laz...@gm...>
* Move rest demos to ./gtk/demo
Ignore-this: 7b9f4784b6d63d1283c7a8a5f5d0eb1b
{
hunk ./demo/unicode/Arabic.hs 1
--- Example of an international dialog box.
-import Graphics.UI.Gtk
-
-import Data.Char
-import Control.Exception
-
-main :: IO ()
-main = do
- initGUI
- dia <- dialogNew
- dialogAddButton dia stockYes ResponseYes
- dialogAddButton dia stockNo ResponseNo
- contain <- dialogGetUpper dia
- theText <- labelNew Nothing [_$_]
- labelSetMarkup theText arabic
- boxPackStartDefaults contain theText
- widgetShowAll dia
- res <- dialogRun dia
- case res of
- ResponseNo -> yell
- _ -> return ()
-
-arabic :: Markup
-arabic = markSpan [FontSize (SizePoint 36)] $
- --"Is Haskell a "++markSpan [FontForeground "red"] "fantastic"++" language?"++
- -- Do you find Haskell a fantastic language? (language has a grammatical
- -- mistake in it)
- map chr [0x647,0x644,32,0x62A,0x62C,0x62F,0x646,32]++
- markSpan [FontForeground "red"] [_$_]
- (map chr [0x647,0x622,0x633,0x643,0x622,0x644])++
- map chr [32,0x644,0x63A,0x62A,32,0x645,0x62F,0x647,0x634,0x62A,0x61F]
-
-yell :: IO ()
-yell = do
- dia <- dialogNew
- dialogAddButton dia stockOk ResponseOk
- contain <- dialogGetUpper dia
- msg <- labelNew (Just "This is not an option.")
- contain `boxPackStartDefaults` msg
- widgetShow msg
- dialogRun dia
- return ()
rmfile ./demo/unicode/Arabic.hs
hunk ./demo/unicode/Makefile 1
-
-PROG = arabic
-SOURCES = Arabic.hs
-
-$(PROG) : $(SOURCES)
- $(HC) --make $< -o $@ $(HCFLAGS)
-
-clean:
- rm -f $(SOURCES:.hs=.hi) $(SOURCES:.hs=.o) $(PROG)
-
-HC=ghc
rmfile ./demo/unicode/Makefile
rmdir ./demo/unicode
binary ./demo/treeList/resListDND/desktop.png
rmfile ./demo/treeList/resListDND/desktop.png
binary ./demo/treeList/resListDND/laptop.png
rmfile ./demo/treeList/resListDND/laptop.png
binary ./demo/treeList/resListDND/laptopSmall.png
rmfile ./demo/treeList/resListDND/laptopSmall.png
binary ./demo/treeList/resListDND/printer.png
rmfile ./demo/treeList/resListDND/printer.png
binary ./demo/treeList/resListDND/server.png
rmfile ./demo/treeList/resListDND/server.png
binary ./demo/treeList/resListDND/tower.png
rmfile ./demo/treeList/resListDND/tower.png
rmdir ./demo/treeList/resListDND
hunk ./demo/treeList/Completion.hs 1
--- Demo to show off entry completion.
-
-import Graphics.UI.Gtk
-import Data.Char
-import Data.List
-
-data ColorDesc = ColorDesc {
- cdColor :: Color,
- cdName :: String
- } deriving Show
-
-compareCol :: ColumnId ColorDesc String
-compareCol = makeColumnIdString 0
-
-invertColor (Color r g b) = Color (32767+r) (32767+g) (32767+b) [_$_]
---Color (65535-r) (65535-g) (65535-b)
-
-parseColor s = ColorDesc c (dropWhile isSpace (upperToSpace name))
- where
- s1 = dropWhile isSpace s
- (s2,s3) = span isDigit s1
- s4 = dropWhile isSpace s3
- (s5,s6) = span isDigit s4
- s7 = dropWhile isSpace s6
- (s8,s9) = span isDigit s7
- n1 = read ('0':s2)
- n2 = read ('0':s5)
- n3 = read ('0':s8)
- c = Color (n1*256+n1) (n2*256+n2) (n3*256+n3)
- name = dropWhile isSpace s9
- upperToSpace [] = []
- upperToSpace (x:xs) | isUpper x = ' ':toLower x:upperToSpace xs
- | otherwise = x:upperToSpace xs
-
-main =
- do
- initGUI
- window <- windowNew
- [_$_]
- contents <- readFile "rgb.txt"
- let killDups [] = []
- killDups [x] = [x]
- killDups (x:y:xs) | cdName x==cdName y = killDups (y:xs)
- | otherwise = x:killDups (y:xs)
- cols = killDups $ map parseColor (drop 1 (lines contents))
- store <- listStoreNew cols
- customStoreSetColumn store compareCol cdName
-
- entry <- entryNew
- completion <- entryCompletionNew
- entrySetCompletion entry completion
-
- set completion [entryCompletionModel := Just store]
- cell <- cellRendererTextNew
- set cell [cellTextBackgroundSet := True,
- cellTextForegroundSet := True]
- cellLayoutPackStart completion cell True
- cellLayoutSetAttributes completion cell store
- (\cd -> [cellText := cdName cd,
- cellTextBackgroundColor := cdColor cd,
- cellTextForegroundColor := invertColor (cdColor cd)])
- entryCompletionSetMatchFunc completion (matchFunc store)
- on completion matchSelected $ \model iter -> do
- color <- treeModelGetValue model iter compareCol
- entrySetText entry color
- return True
- set window [containerChild := entry]
- widgetShowAll window
- onDestroy window mainQuit
- mainGUI
-
-matchFunc :: ListStore ColorDesc -> String -> TreeIter -> IO Bool
-matchFunc model str iter = do
- --putStrLn ("iter is "++show iter)
- tp <- treeModelGetPath model iter
- r <- case tp of
- (i:_) -> do row <- listStoreGetValue model i
- return $ any (isPrefixOf (map toLower str))
- (words (map toLower (cdName row)))
- otherwise -> return False
- return r
-
rmfile ./demo/treeList/Completion.hs
hunk ./demo/treeList/DirList.hs 1
-{-# OPTIONS -cpp #-}
--- Test file for the ListView widget.
-module Main(main) where
-
-import Graphics.UI.Gtk
-import Graphics.UI.Gtk.ModelView as New
-
-import Control.Exception
-import System.Directory
-import System.IO
-import System.Locale
-import System.Time
-
-data FileInfo = FileInfo {
- fName :: String,
- fSize :: Integer,
- fTime :: ClockTime
-}
-
-main = do
- initGUI
- win <- windowNew
- win `onDestroy` mainQuit
-
- curDir <- getCurrentDirectory
- files <- getDirectoryContents curDir
- fInfos <- (flip mapM) files $ \f -> do
- s <- handle (\e ->
-#if __GLASGOW_HASKELL__>=610
- case e :: SomeException of
- e ->
-#endif
- return 0) $ do
- h <- openFile f ReadMode
- s <- hFileSize h
- hClose h
- return s
- t <- getModificationTime f
- return FileInfo { fName = f
- , fSize = s
- , fTime = t }
-
- store <- New.listStoreNew fInfos
-
- tv <- New.treeViewNewWithModel store
- containerAdd win tv
-
- tvc <- New.treeViewColumnNew
- set tvc [ New.treeViewColumnTitle := "File name"
- , New.treeViewColumnResizable := True ]
- New.treeViewAppendColumn tv tvc
-
- name <- New.cellRendererTextNew
- New.treeViewColumnPackStart tvc name True
- New.cellLayoutSetAttributes tvc name store $ \FileInfo { fName = name } ->
- [ New.cellText := name ]
-
- tvc <- New.treeViewColumnNew
- set tvc [ New.treeViewColumnTitle := "Size"
- , New.treeViewColumnResizable := True ]
- New.treeViewAppendColumn tv tvc
-
- size <- New.cellRendererTextNew
- New.treeViewColumnPackStart tvc size True
- New.cellLayoutSetAttributes tvc size store $ \FileInfo { fSize = size } ->
- [ New.cellText := show size ]
-
- tvc <- New.treeViewColumnNew
- set tvc [ New.treeViewColumnTitle := "Modification time"
- , New.treeViewColumnResizable := True ]
- New.treeViewAppendColumn tv tvc
-
- time <- New.cellRendererTextNew
- New.treeViewColumnPackStart tvc time True
- New.cellLayoutSetAttributes tvc time store $ \FileInfo { fTime = time } ->
- [ New.cellText :=> do
- calTime <- toCalendarTime time
- return (formatCalendarTime defaultTimeLocale "%D %T" calTime)
- ]
-
- widgetShowAll win
- mainGUI
rmfile ./demo/treeList/DirList.hs
hunk ./demo/treeList/FilterDemo.hs 1
--- a demo that shows how to create a normal tree view and a tree view in
--- which only a chosen subset of rows are shown (namely those with upper case letters)
-module Main ( main ) where
-
-import Graphics.UI.Gtk
-import Data.List
-import Data.Char
-import Debug.Trace
-
--- | Define a virtual column of the model that determines the visibility of a row in
--- the model.
-visCol :: ColumnId String Bool
-visCol = makeColumnIdBool 0
-
-main = do
- initGUI
- [_$_]
- win <- windowNew
- onDestroy win mainQuit
- [_$_]
- content <- readFile "FilterDemo.hs"
-
- -- create a view that shows all lines
- model <- listStoreNew (lines content)
- viewAll <- treeViewNewWithModel model
- col <- treeViewColumnNew
- ren <- cellRendererTextNew
- cellLayoutPackStart col ren True
- cellLayoutSetAttributes col ren model $ \row -> [ cellText := row ]
- treeViewAppendColumn viewAll col
-
- -- create a view that only shows lines with upper case characters
- fModel <- treeModelFilterNew model []
-
- -- create a virtual column 'visCol' that contains @True@ if a certain row has
- -- upper case letters. Then set this column to determine the visibility of a row.
- customStoreSetColumn model visCol (any isUpper)
- treeModelFilterSetVisibleColumn fModel visCol
-
-{-
- -- this is an alternative way to determine the visibility of a row. In this case,
- -- it is not necessary to create the column 'visCol'.
- treeModelFilterSetVisibleFunc fModel $ Just $ \iter -> do
- row <- treeModelGetRow model iter
- return (any isUpper row)
--}
- -- note: it is important to insert the model into the view after the visibility
- -- row or the visibility function have been set. Otherwise, the view is filled
- -- first and setting a new visibility column/function will not update the view.
- viewFew <- treeViewNewWithModel fModel
- col <- treeViewColumnNew
- ren <- cellRendererTextNew
- cellLayoutPackStart col ren True
- cellLayoutSetAttributes col ren model $ \row -> [ cellText := row ]
-
- treeViewAppendColumn viewFew col
- [_$_]
- [_$_]
- [_$_]
- box <- vBoxNew False 0
- swAll <- scrolledWindowNew Nothing Nothing
- containerAdd swAll viewAll
- boxPackStart box swAll PackGrow 4
-
- swFew <- scrolledWindowNew Nothing Nothing
- containerAdd swFew viewFew
- boxPackEnd box swFew PackGrow 4
- [_$_]
- containerAdd win box
- widgetShowAll win
- mainGUI
rmfile ./demo/treeList/FilterDemo.hs
hunk ./demo/treeList/ListDND.hs 1
-module Main where
-
-import Graphics.UI.Gtk
-import Graphics.UI.Gtk.Gdk.EventM
-
-import System.Glib.GObject ( toGObject )
-import System.FilePath
-import Control.Concurrent.MVar
-import Control.Monad ( liftM )
-import Control.Monad.Trans ( liftIO )
-import Data.Maybe ( fromMaybe )
-import Data.List ( findIndex )
-
-roomStrCol :: ColumnId String String
-roomStrCol = makeColumnIdString 1
-
--- Define a string column and an image column on the store holding the
--- computer types.
-compPicCol :: ColumnId CompType Pixbuf
-compPicCol = makeColumnIdPixbuf 1
-
-compStrCol :: ColumnId CompType String
-compStrCol = makeColumnIdString 2
-
-data Computer = Computer {
- name :: String,
- addr :: (Int, Int, Int, Int),
- roomStore :: ListStore String,
- roomSel :: Int,
- cType :: CompType }
-
-data CompType
- = MacBookPro
- | MacBook
- | Printer
- | MacPro
- | Xserve
- | IMac
- deriving (Enum, Bounded, Show)
-
-showCT :: CompType -> String
-showCT ct = case show ct of
- 'I':xs -> 'i':xs
- xs -> xs
-
-main = do
- initGUI
-
- win <- windowNew
- onDestroy win mainQuit
-
- -- create a tag that we use as selection, target and selection type
- compTypeTag <- atomNew "_CompType"
-
- let pNames = map ("resListDND" </>)
- ["laptop.png","laptopSmall.png","printer.png",
- "tower.png","server.png","desktop.png"]
- pics <- mapM pixbufNewFromFile pNames
-
- smallPics <- mapM (\n -> pixbufNewFromFileAtScale n 48 48 True) pNames
-[_^I_][_$_]
- [noRoom, publicRoom, restrictedRoom] <- mapM listStoreNew
- [["Paul (Home)","John (Home)","Fred (Home)"],
- ["N12","S112", "S113", "S114"],
- ["Server Room Upstairs", "Server Room Downstairs"]]
-
- -- define extractor function for the string column
- treeModelSetColumn noRoom roomStrCol id
- treeModelSetColumn publicRoom roomStrCol id
- treeModelSetColumn restrictedRoom roomStrCol id
- [_$_]
- let genRoomStore MacBookPro = noRoom
- genRoomStore MacBook = noRoom
- genRoomStore Printer = publicRoom
- genRoomStore MacPro = publicRoom
- genRoomStore Xserve = restrictedRoom
- genRoomStore IMac = publicRoom
-
- -- the initial computer list - it's a coincidence that there's
- -- one computer of each type
- content <- listStoreNewDND [_$_]
- (map (\t -> Computer { name = showCT t, addr = (192,168,0,fromEnum t+1),
- roomStore = genRoomStore t, roomSel = 0, cType = t})
- [minBound :: CompType .. maxBound])
- (Just listStoreDefaultDragSourceIface)
- (Just DragDestIface {
- treeDragDestRowDropPossible = \store path@(i:_) -> do
- mCT <- selectionDataGet compTypeTag
- case mCT :: Maybe [Int] of
- Just [ct] -> return True
- Nothing ->
- (treeDragDestRowDropPossible listStoreDefaultDragDestIface)
- store path
- _ -> return False,
- treeDragDestDragDataReceived = \store path@(i:_) -> do
- mCT <- selectionDataGet compTypeTag
- case mCT of
- Just [ct] -> do
- let t = toEnum ct
- liftIO $ listStoreInsert store i
- Computer { name = showCT t, addr = (192,168,0,254),
- roomStore = genRoomStore t, roomSel = 0,
- cType = t }
- return True
- Nothing ->
- (treeDragDestDragDataReceived listStoreDefaultDragDestIface)
- store path
- })
- -- the area with the possible computer types
- compTypes <- listStoreNewDND [minBound :: CompType .. maxBound]
- (Just DragSourceIface {
- treeDragSourceRowDraggable = \store (i:_) -> return True,
- treeDragSourceDragDataGet = \store (i:_) -> do
- ty <- selectionDataGetTarget
- ct <- liftIO $ listStoreGetValue store i
- selectionDataSet compTypeTag [fromEnum ct]
- return True,
- treeDragSourceDragDataDelete = \store path -> return True
- })
- Nothing
-
- -- define extractor functions for the two column
- treeModelSetColumn compTypes compPicCol $
- \t -> pics !! fromEnum t
- treeModelSetColumn compTypes compStrCol showCT
- [_$_]
- -- create an icon view of all the computer types
- typesView <- iconViewNew
- set typesView [iconViewModel := Just compTypes,
- iconViewPixbufColumn := compPicCol,
- iconViewTextColumn := compStrCol,
- iconViewColumns := 6] [_$_]
-
- -- create an editable list of computers
- inventory <- treeViewNewWithModel content
-
- tyCol <- treeViewColumnNew
- treeViewColumnSetTitle tyCol "Type"
- picRen <- cellRendererPixbufNew
- treeViewColumnPackStart tyCol picRen False
- cellLayoutSetAttributes tyCol picRen content
- (\Computer { cType = t} -> [cellPixbuf := smallPics !! fromEnum t])
- tyRen <- cellRendererTextNew
- treeViewColumnPackStart tyCol tyRen False
- cellLayoutSetAttributes tyCol tyRen content
- (\Computer { cType = t} -> [cellText := showCT t])
- treeViewAppendColumn inventory tyCol
-
- nameCol <- treeViewColumnNew
- treeViewColumnSetTitle nameCol "Name"
- treeViewColumnSetResizable nameCol True
- treeViewColumnSetMinWidth nameCol 100
- nameRen <- cellRendererTextNew
- set nameRen [ cellTextEditable := True,
- cellTextEditableSet := True,
- cellTextEllipsize := EllipsizeEnd,
- cellTextEllipsizeSet := True]
- treeViewColumnPackStart nameCol nameRen True
- cellLayoutSetAttributes nameCol nameRen content
- (\Computer { name = n } -> [cellText := n])
- treeViewAppendColumn inventory nameCol
- on nameRen edited $ \[i] str -> do
- val <- listStoreGetValue content i
- listStoreSetValue content i val { name = str }
-
- addrCol <- treeViewColumnNew
- treeViewColumnSetTitle addrCol "Address"
- oct1 <- cellRendererTextNew
- dot1 <- cellRendererTextNew
- oct2 <- cellRendererTextNew
- dot2 <- cellRendererTextNew
- oct3 <- cellRendererTextNew
- dot3 <- cellRendererTextNew
- oct4 <- cellRendererTextNew
- mapM_ (uncurry (cellLayoutPackStart addrCol))
- [(oct1, True), (dot1, False), (oct2, True),
- (dot2, False), (oct3, True), (dot3, False), (oct4, True)]
- mapM_ (\d -> set d [cellText := ".",
- cellTextWidthChars := 0]) [dot1, dot2, dot3]
- mapM_ (\o -> set o [cellXAlign := 1.0,
- cellTextWidthChars := 3]) [oct1, oct2, oct3, oct4]
- cellLayoutSetAttributes addrCol oct1 content
- (\Computer { addr = (o1,_,_,_)} -> [cellText := show o1])
- cellLayoutSetAttributes addrCol oct2 content
- (\Computer { addr = (_,o2,_,_)} -> [cellText := show o2])
- cellLayoutSetAttributes addrCol oct3 content
- (\Computer { addr = (_,_,o3,_)} -> [cellText := show o3])
- cellLayoutSetAttributes addrCol oct4 content
- (\Computer { addr = (_,_,_,o4)} -> [cellText := show o4]) [_$_]
- treeViewAppendColumn inventory addrCol
-
- roomCol <- treeViewColumnNew
- treeViewColumnSetTitle roomCol "Room"
- treeViewColumnSetResizable roomCol True
- treeViewColumnSetSizing roomCol TreeViewColumnAutosize
- roomRen <- cellRendererComboNew
- set roomRen [ cellTextEditable := True,
- cellTextEditableSet := True,
- cellComboHasEntry := True ]
- treeViewColumnPackStart roomCol roomRen True
- cellLayoutSetAttributes roomCol roomRen content
- (\Computer { roomStore = t, roomSel = idx } ->
- [cellText :=> listStoreGetValue t idx,
- cellComboTextModel := (t, roomStrCol)])
- on roomRen edited $ \[i] str -> do
- row@Computer { roomStore = t } <- listStoreGetValue content i
- elems <- listStoreToList t
- idx <- case (findIndex ((==) str) elems) of
- Just idx -> return idx
- Nothing -> listStoreAppend t str
- listStoreSetValue content i row { roomSel = idx }
- treeViewAppendColumn inventory roomCol
-
- -- make typesView a drag source for compTypeTag values
- tl <- targetListNew
- targetListAdd tl compTypeTag [TargetSameApp] 0
- iconViewEnableModelDragSource typesView [Button1] tl [ActionCopy]
- [_$_]
- -- Due to a bug in Gtk+, the treeDragSourceDragDataGet handler in
- -- the DND source handler is not called unless the IconView is also
- -- set to be a DND destination. Bugzilla 550528
- tl <- targetListNew
- iconViewEnableModelDragDest typesView tl []
- [_$_]
- -- make the inventory widget a drag destination for compTypeTag values
- tl <- targetListNew
- targetListAdd tl compTypeTag [TargetSameApp] 0
- targetListAdd tl targetTreeModelRow [TargetSameWidget] 0
- treeViewEnableModelDragDest inventory tl [ActionMove]
- tl <- targetListNew
- targetListAdd tl targetTreeModelRow [TargetSameWidget] 0
- treeViewEnableModelDragSource inventory [Button1] tl [ActionMove]
- [_$_]
- -- Install drag and drop for permuting rows. This is now done above using
- -- the explicit target 'targetTreeModelRow'. Calling the function below
- -- will set a completely new 'TargetList' thereby removing our own
- -- 'compTypeTag' from the inventory widget's target list.
- [_$_]
- --treeViewSetReorderable inventory True
-
- -- arrange the widgets
- v <- vPanedNew
- panedAdd1 v typesView
- panedAdd2 v inventory
- containerAdd win v
-
- widgetShowAll win
- mainGUI [_$_]
rmfile ./demo/treeList/ListDND.hs
hunk ./demo/treeList/ListDemo.hs 1
-module Main where
-
-import Graphics.UI.Gtk
-import System.Glib.Signals (on)
-import Data.List ( isPrefixOf )
-import Data.Char ( toLower )
-
-data Phone = Phone { name :: String, number :: Int, marked :: Bool }
-
-main = do
- initGUI
-
- win <- windowNew
- onDestroy win mainQuit
-
- -- create a new list model
- model <- listStoreNew
- [Phone { name = "Foo", number = 12345, marked = False }
- ,Phone { name = "Bar", number = 67890, marked = True }
- ,Phone { name = "Baz", number = 39496, marked = False }]
- view <- treeViewNewWithModel model
- [_$_]
- treeViewSetHeadersVisible view True
-
- -- add a couple columns
- col1 <- treeViewColumnNew
- col2 <- treeViewColumnNew
- col3 <- treeViewColumnNew
-
- treeViewColumnSetTitle col1 "String column"
- treeViewColumnSetTitle col2 "Int column"
- treeViewColumnSetTitle col3 "Bool column"
-
- renderer1 <- cellRendererTextNew
- renderer2 <- cellRendererTextNew
- renderer3 <- cellRendererToggleNew
-
- cellLayoutPackStart col1 renderer1 True
- cellLayoutPackStart col2 renderer2 True
- cellLayoutPackStart col3 renderer3 True
-
- cellLayoutSetAttributes col1 renderer1 model $ \row -> [ cellText := name row ]
- cellLayoutSetAttributes col2 renderer2 model $ \row -> [ cellText := show (number row) ]
- cellLayoutSetAttributes col3 renderer3 model $ \row -> [ cellToggleActive := marked row ]
-
- treeViewAppendColumn view col1
- treeViewAppendColumn view col2
- treeViewAppendColumn view col3
-
- -- update the model when the toggle buttons are activated
- on renderer3 cellToggled $ \pathStr -> do
- let (i:_) = stringToTreePath pathStr
- val <- listStoreGetValue model i
- listStoreSetValue model i val { marked = not (marked val) }
-
-
- -- enable interactive search
- treeViewSetEnableSearch view True
- treeViewSetSearchEqualFunc view $ Just $ \str iter -> do
- (i:_) <- treeModelGetPath model iter
- row <- listStoreGetValue model i
- return (map toLower str `isPrefixOf` map toLower (name row))
- [_$_]
- containerAdd win view
- widgetShowAll win
- mainGUI [_$_]
rmfile ./demo/treeList/ListDemo.hs
hunk ./demo/treeList/ListTest.glade 1
-<?xml version="1.0" standalone="no"?> <!--*- mode: xml -*-->
-<!DOCTYPE glade-interface SYSTEM "http://glade.gnome.org/glade-2.0.dtd">
-
-<glade-interface>
-
-<widget class="GtkWindow" id="window">
- <property name="visible">True</property>
- <property name="title" translatable="yes">List Test</property>
- <property name="type">GTK_WINDOW_TOPLEVEL</property>
- <property name="window_position">GTK_WIN_POS_NONE</property>
- <property name="modal">False</property>
- <property name="resizable">True</property>
- <property name="destroy_with_parent">False</property>
- <property name="decorated">True</property>
- <property name="skip_taskbar_hint">False</property>
- <property name="skip_pager_hint">False</property>
- <property name="type_hint">GDK_WINDOW_TYPE_HINT_NORMAL</property>
- <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
- <property name="focus_on_map">True</property>
-
- <child>
- <widget class="GtkVBox" id="vbox1">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">0</property>
-
- <child>
- <widget class="GtkScrolledWindow" id="scrolledwindow1">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="hscrollbar_policy">GTK_POLICY_ALWAYS</property>
- <property name="vscrollbar_policy">GTK_POLICY_ALWAYS</property>
- <property name="shadow_type">GTK_SHADOW_IN</property>
- <property name="window_placement">GTK_CORNER_TOP_LEFT</property>
-
- <child>
- <widget class="GtkTreeView" id="view">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="headers_visible">True</property>
- <property name="rules_hint">False</property>
- <property name="reorderable">False</property>
- <property name="enable_search">True</property>
- <property name="fixed_height_mode">False</property>
- <property name="hover_selection">False</property>
- <property name="hover_expand">False</property>
- </widget>
- </child>
- </widget>
- <packing>
- <property name="padding">0</property>
- <property name="expand">True</property>
- <property name="fill">True</property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkHBox" id="hbox1">
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">0</property>
-
- <child>
- <widget class="GtkVBox" id="vbox2">
- <property name="border_width">8</property>
- <property name="visible">True</property>
- <property name="homogeneous">False</property>
- <property name="spacing">12</property>
-
- <child>
- <widget class="GtkExpander" id="expander6">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="expanded">True</property>
- <property name="spacing">0</property>
-
- <child>
- <widget class="GtkTable" id="table1">
- <property name="border_width">2</property>
- <property name="visible">True</property>
- <property name="n_rows">3</property>
- <property name="n_columns">2</property>
- <property name="homogeneous">False</property>
- <property name="row_spacing">2</property>
- <property name="column_spacing">18</property>
-
- <child>
- <widget class="GtkSpinButton" id="intValue">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="climb_rate">1</property>
- <property name="digits">0</property>
- <property name="numeric">True</property>
- <property name="update_policy">GTK_UPDATE_ALWAYS</property>
- <property name="snap_to_ticks">True</property>
- <property name="wrap">False</property>
- <property name="adjustment">1 0 100 1 10 10</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkCheckButton" id="boolValue">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- <property name="focus_on_click">True</property>
- <property name="active">False</property>
- <property name="inconsistent">False</property>
- <property name="draw_indicator">True</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
- <widget class="GtkLabel" id="label2">
- <property name="visible">True</property>
- <property name="label" translatable="yes">String value:</property>
- <property name="use_underline">False</property>
- <property name="use_markup">False</property>
- <property name="justify">GTK_JUSTIFY_LEFT</property>
- <property name="wrap">False</property>
- <property name="selectable">False</property>
- <property name="xalign">1</property>
- <property name="yalign">0.5</property>
- <property name="xpad">0</property>
- <property name="ypad">0</property>
- <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
- <property name="width_chars">-1</property>
- <property name="single_line_mode">False</property>
- <property name="angle">0</property>
- </widget>
- <packing>
...
[truncated message content] |