[Haskell-cafe] HTTP and Browser modules
Good morning I have a query about compiling the original version of the HTTP implementation in Windows (http://homepages.paradise.net.nz/warrickg/haskell/http/). Using the compile commands stipulated a series of similar errors to do with the HTTP module appear. They are to do with a type mismatch, one of these errors for example is: ./HTTP.hs:592: Couldn't match 'IOError' against 'Exception' Expected type: Exception - IO (Either a [Char]) Inferred type: IOError - IO (Either ConnError b) In the application 'handleSocketError sk' In the second argument of 'Control.Exception.catch', namely '(handleSocketError sk)' Line 592 is: readBlock sk n = (liftM Right $ fn n) `Exception.catch` (handleSocketError sk) Have hacked about for some time to no avail. I don't know why this occurs because the code appears exactly the same in the updated version (http://www.dtek.chalmers.se/~d00bring/haskell-xml-rpc/http.html) and that compiles, albeit in linux only due to the Cabal constraint. I need it to work in Windows though so must use the original version. (I need it to compile using GHC 6.2.2) If anybody has seen this problem before or knows how to correct it I'd be very interested in your assistance :-) cheers to all david ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell-cafe] wxHaskell htmlWindow usage
Good day all, I am attempting to display html pages using wxHaskell's HtmlWindow functions. I am hoping that it is indeed possible for me to do just that and that I haven't misunderstood what HtmlWindow is used for. My code so far will create a frame, a button and an HtmlWindow and other assorted things. I would like an html file to be displayed in the window when the button is clicked. At the moment, only the path (a string) of the html file that I would like to display is printed in the window when the button is clicked. Here is some of the code i've been trying to get to do this: do -- the main frame f - frame [text := Browser, fullRepaintOnResize := False] -- create html window hw - htmlWindowCreate f 1 (Rect 50 150 50 150) 5 theWindow -- 'load page' button go - button f [text := Load Page, on command := htmlWindowSetPage hw c:/example.html] (I've left out the layout part here) htmlWindowSetPage might be the wrong function to use for this or I might just be using it incorrectly. This may well be more complicated than I'm hoping it is too! Thankyou to whoever has a look at this. bye all David ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell-cafe] Re: GUI components for displaying Html pages
Lemmih Wrote: Is this what you're looking for: http://wxhaskell.sourceforge.net/doc/Graphics.UI.WXCore.WxcClassesAL.html#88 ? -- Friendly, Lemmih That looks about right. I hadn't delved that far into WXCore library to spot all of those components. I shall have a go with them. Thanks! David ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell-cafe] GUI components for displaying Html pages
Hi all, I'm looking for a Haskell GUI library which supports the display of rendered Html pages in the same way that web browsers do. I've been getting to grips recently with wxHaskell as it was recommended on haskell-cafe. I was hoping that a special pane component (or something similar) existed in wxHaskell for the purpose. I've looked through the API but can't seem to see anything which looks suitable. Does anybody know if wxHaskell can support this? If not is anybody aware of a Haskell GUI library which caters for this purpose. Also, I am hoping to make use of HaXmL to deal with the Html parsing or failing that attempt a very simple home-made parser. Should anybody out there know of a better way of attacking this aspect then that would be much appreciated too! (Apologies, this email might have been better suited to the libraries mailing list!) Cheers all! David (Swansea, UK) ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell-cafe] RE: Answers to Exercises in Craft of FP
Gour ([EMAIL PROTECTED]) wrote RE- : Do you know if there are solutions to exersises available somewhere? Have you gone through the whole book, i.e. all the exercises? Sincerely, Gour Hi Gour, Unfortuantely I don't know of anywhere that the exercise answers can be found, even after some google searching. I would definitely find them useful though as there are a couple I haven't been able to work out. I can't say I've gone through all the exercises yet but I'll get there one day! I've got as far as the abstract data types chapter. regards DaveO ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell-cafe] Re: Books on Haskell
Hi, I have 3 Haskell books, The Craft of Functional Programming (Thompson), Introduction to Functional Programming Using Haskell (Bird) and The Haskell School of Expression (Hudak). I recommend Thompson's book because it contains good explanations and lots of exercises, although the book is quite big and takes some time to work through. Bird's book is a bit shorter and is good for explanations too but it isn't quite so hands on as it contains fewer exercises. Hudak's I feel is a bit too advanced for a first read, it focusses on using the Hugs graphics library and I think that the graphics examples can sometimes cloud the simple ideas that are trying to be explained. I'll probably try reading it again in the future. All the best Dave O ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe