Personal tools

WinHugs

From HaskellWiki

(Difference between revisions)
Jump to: navigation, search
 
(old link defunct, linking to googlecode)
 
(15 intermediate revisions by 4 users not shown)
Line 1: Line 1:
WinHugs is the Windows user interface to [[Hugs]]. Further details, including a preview download, are available [http://www-users.cs.york.ac.uk/~ndm/projects/winhugs.php here]. In addition to all of the [[Hugs]] features, it includes type browsers and heirarchical constraint views. WinHugs should run on any version of Windows since 95, i.e. 95/98/ME/NT/2K/XP.
+
'''WinHugs''' is the Windows user interface to [[Hugs]]. Further details, including a preview download, are available [http://code.google.com/p/ndmitchell/ here]. In addition to all of the [[Hugs]] features, it includes type browsers and hierarchical constraint views. WinHugs should run on any version of Windows since 95, i.e. 95/98/ME/NT/2K/XP. A list of bugs and features is maintained [[/Bugs|here]]. I am considering rewriting some parts, especially the main user interface. If you want to have your say [[/Future|comment on this page]].
   
http://www-users.cs.york.ac.uk/~ndm/projects/winhugs/winhugs.png
+
== WinHugs manual entry ==
   
== Existing Bugs ==
+
''This section is intended to become the official entry in the Hugs user guide''
   
These are bugs that remain, relative to the last stable release of WinHugs (a ''long'' time ago).
+
----
   
* Add cpphs support, so can compile with cpp directives
+
== Overview ==
* Should be an option to list all files not in the Hugs directory loaded
 
* Excessive clearing of previous part of the screen, once it goes over the limit
 
* Inline system calls, i.e. "system dir" returns the results to the terminal.
 
* Doesn't work on Windows 98
 
   
== Ignored Issues ==
+
'''WinHugs''' is a Windows user interface to [[Hugs]]. It provides an environment in which to experiment with Haskell commands in much the same way as Hugs, but instead of using a console and textual commands to perform operations such as loading, buttons are provided. It is intended to be more user friendly, and more approachable for new users.
   
I'm not sure if these are bugs or not, but people reported them, although fixing them breaks more things.
+
[[Image:Winhugs_screenshot.png|Screenshot of WinHugs]]
   
* Open textpad with new command: C:\Program Files\TextPad 4\TextPad.exe -s %s(%d) [fixes DDE problems on certain systems, opens multiple instances on others...]
+
== Features ==
* :edit starts editing a weird file. Should create a new file in my documents and open that.
 
   
== Polish ==
+
WinHugs has all the Haskell features of [[Hugs]], plus a few others not found with the Windows version of Hugs
   
These aren't really bugs, they just need looking at before a final release. Mainly just polishing rough edges and checking for consistency.
+
* Colored output, the prompt and various other items are colorised to aid reading.
  +
* Some escape codes are supported, in particular those which change the foreground and background color.
  +
* Hyperlinks and editor integration, when an error occurs a link can be clicked to open an editor at the appropriate line.
  +
* Easy control of options, in a convenient dialog.
  +
* Easy access to some commands, such as load.
  +
* Browse commands to view the type hierarchy and items in scope.
   
* Unicode
+
== Getting started ==
* update the documentation
 
* keyboard accelerators, Ctrl+C, Ctrl+V etc.
 
* correctly align and space the options dialog
 
* add more text editor support (as people ask!)
 
   
== Good Points About the Rewrite ==
+
This is just a simple guide to get you started with WinHugs, and give you a small introduction to some of its features.
  +
  +
Create a file, called Main.hs, and inside put the text
  +
  +
module Main where
  +
main = putStrLn "Hello, WinHugs!"
  +
  +
Now run WinHugs, and click on open (File/Open) and browse to the file Main.hs. It will open in WinHugs. Now click on the run button, and watch it say a message.
  +
  +
Now modify the program to say
  +
  +
module Main where
  +
main = putStrLn "Hello, WinHugs!
  +
  +
Note that no closing quote is given, so this program will crash. Now click on the refresh button in WinHugs, or type :r (all the Hugs commands still work). Note that this time an error is given, along with a link saying where the error. Click this link, and the file will open in your editor, at the appropriate line.
  +
  +
If the file doesn't open at the correct line, visit the options, and under the WinHugs set Editor value appropriately.
  +
  +
This overview has presented some of the most commonly used features in WinHugs. WinHugs can also be used exactly like Hugs for most uses, with command history, commands like :quit etc.
  +
  +
----
  +
  +
== Who should use WinHugs? ==
  +
  +
WinHugs is only available on Windows. If you are a Windows user who wants a quick haskell environment to test out your ideas and programs, then WinHugs may certainly be an option. If you are a fan of the console, or if you need your program to go really fast (even while you are developing it), then [[GHC]] might be a better choice.
  +
  +
== Authorship ==
  +
  +
The code is currently maintained by [[User:NeilMitchell|Neil Mitchell]], and has been rewritten from scratch. Previous versions were written by ...
  +
  +
== Good points about the rewrite ==
   
 
* Rewritten to use less code
 
* Rewritten to use less code
Line 34: Line 34:
 
* Hyperlinks for errors
 
* Hyperlinks for errors
 
* Better support for interact and getChar
 
* Better support for interact and getChar
  +
  +
[[Category:Implementations]]

Latest revision as of 18:50, 12 April 2009

WinHugs is the Windows user interface to Hugs. Further details, including a preview download, are available here. In addition to all of the Hugs features, it includes type browsers and hierarchical constraint views. WinHugs should run on any version of Windows since 95, i.e. 95/98/ME/NT/2K/XP. A list of bugs and features is maintained here. I am considering rewriting some parts, especially the main user interface. If you want to have your say comment on this page.

Contents

[edit] 1 WinHugs manual entry

This section is intended to become the official entry in the Hugs user guide


[edit] 2 Overview

WinHugs is a Windows user interface to Hugs. It provides an environment in which to experiment with Haskell commands in much the same way as Hugs, but instead of using a console and textual commands to perform operations such as loading, buttons are provided. It is intended to be more user friendly, and more approachable for new users.

Screenshot of WinHugs

[edit] 3 Features

WinHugs has all the Haskell features of Hugs, plus a few others not found with the Windows version of Hugs

  • Colored output, the prompt and various other items are colorised to aid reading.
  • Some escape codes are supported, in particular those which change the foreground and background color.
  • Hyperlinks and editor integration, when an error occurs a link can be clicked to open an editor at the appropriate line.
  • Easy control of options, in a convenient dialog.
  • Easy access to some commands, such as load.
  • Browse commands to view the type hierarchy and items in scope.

[edit] 4 Getting started

This is just a simple guide to get you started with WinHugs, and give you a small introduction to some of its features.

Create a file, called Main.hs, and inside put the text

module Main where
main = putStrLn "Hello, WinHugs!"

Now run WinHugs, and click on open (File/Open) and browse to the file Main.hs. It will open in WinHugs. Now click on the run button, and watch it say a message.

Now modify the program to say

module Main where
main = putStrLn "Hello, WinHugs!

Note that no closing quote is given, so this program will crash. Now click on the refresh button in WinHugs, or type :r (all the Hugs commands still work). Note that this time an error is given, along with a link saying where the error. Click this link, and the file will open in your editor, at the appropriate line.

If the file doesn't open at the correct line, visit the options, and under the WinHugs set Editor value appropriately.

This overview has presented some of the most commonly used features in WinHugs. WinHugs can also be used exactly like Hugs for most uses, with command history, commands like :quit etc.


[edit] 5 Who should use WinHugs?

WinHugs is only available on Windows. If you are a Windows user who wants a quick haskell environment to test out your ideas and programs, then WinHugs may certainly be an option. If you are a fan of the console, or if you need your program to go really fast (even while you are developing it), then GHC might be a better choice.

[edit] 6 Authorship

The code is currently maintained by Neil Mitchell, and has been rewritten from scratch. Previous versions were written by ...

[edit] 7 Good points about the rewrite

  • Rewritten to use less code
  • Redesigned options, better layed out
  • Easier integration with text editors, just textpad for now but ask for more
  • Better designed menus
  • Updated artwork, hicolor large size
  • Uses XP style
  • Faster on output, about 5 times
  • About twice as fast as the console version of Hugs on Windows
  • Can use drag/drop and cut/copy/paste better
  • Hyperlinks for errors
  • Better support for interact and getChar