[Haskell-beginners] Help with Glade

Paul Johnston Paul.A.Johnston at manchester.ac.uk
Mon Sep 1 18:21:02 EDT 2008


Sorry if it's a bit off topic but could anyone give me some pointers.
I'm trying to get glade-3 to work with ghc.

Installed ghc  (works fine!)

paulj at linux-yrwq:~/haskell> ghci
GHCi, version 6.8.3: http://www.haskell.org/ghc/  :? for help
Loading package base ... linking ... done.
Prelude>  

Installed Gtk2Hs
The hello world program 

import Graphics.UI.Gtk
main :: IO ()
main = do
  initGUI
  window <- windowNew
  button <- buttonNew
  set window [ containerBorderWidth := 10,
               containerChild := button ]
  set button [ buttonLabel := "Hello World" ]
  onClicked button (putStrLn "Hello World")
  onDestroy window mainQuit
  widgetShowAll window
  mainGUI

(works fine!)

Install Glade-3 (3.4.5) works great as a standalone

However when trying to import Glade using the snippet below:

module Main where

import Graphics.UI.Gtk
import Graphics.UI.Gtk.Glade

I get:


paulj at linux-yrwq:~/haskell> ghc --make hello3.hs -o hello3

hello3.hs:4:7:
    Could not find module `Graphics.UI.Gtk.Glade':
      Use -v to see a list of the files searched for.

I'm fairly certain I'm missing an entry in package.conf as there are ones for 
glib and cairo!

Any thoughts gratefully accepted.

Paul




More information about the Beginners mailing list