DeskLib

From RISC OS

(Difference between revisions)
Jump to: navigation, search
m (Reverted edit of GwzEgs, changed back to last version by Adamr)
(New page to go with new release)
Line 1: Line 1:
-
==DeskLib - C Wimp Library for RISC OS==
+
''<font size=+1>C Wimp Library for RISC OS</font>''
-
===Development Versions===
+
==Introduction==
-
There is no recent release at this time.  For a current version, you should [[DeskLib#Getting_the_source|get the source from SVN]]. For use with [[GCCSDK]] and its autobuilder, you can build the 'desklib' package as per [[Using GCCSDK]].
+
DeskLib is a fully-sourced, general-purpose freeware C library for writing desktop applications for RISC OS. It provides comprehensive support for window and icon manipulation, menu creation, graphics routines, message handling, filing operations, font handling, string manipulation and much more. High level event management functions are provided in order to build coherent and powerful code.
-
===7th May 2005 - DeskLib 2.70 release===
+
==Download==
-
This version is 32-bit, and only suitable for compiling and linking with 32-bit compilers and libraries. DeskLib has been carefully designed
+
===Latest Release===
-
to work properly with almost all combinations of RISC OS compilers and C libraries.
+
The current version of DeskLib is 2.80, released in July 2007. It is made up of three zip files:
 +
*[http://www.riscos.info/downloads/DeskLib-2.80/core.zip Core] contains everything needed to use the library, including documentation.
 +
*[http://www.riscos.info/downloads/DeskLib-2.80/source.zip Source] contains the C and assembler source which makes up the library functions.
 +
*[http://www.riscos.info/downloads/DeskLib-2.80/examples.zip Examples] has practical examples on how to use the different parts of DeskLib.
-
For more information about 32-bit, see [[32bit|RISC OS and 32-bit]]
+
===Changes===
 +
Changes since version 2.70 include:
 +
* Several important bugfixes, optimisations and a couple of API changes in Sprite.
 +
* Provided 'sprite by pointer' in addition to 'sprite by name' routines (named as Sprite_*P()).
 +
* Added Sprite_SetPointerShape()/Sprite_SetPointerShapeP().
 +
* Some extra examples
 +
* Tinct support
 +
* Rationalised documentation including an updated StrongHelp manual
 +
* Minor additions to the Icon and Window modules
-
DeskLib 2.70 can be downloaded from the [http://www.riscos.info/downloads/DeskLib-2.70/ downloads] section.
+
For older changes, see the [[DeskLib Changes|changes]] page.
-
==Version History==
+
==Documentation==
 +
===Manuals===
 +
Descriptions of the functions, structures, types etc are included with the ''Core'' download in [[StrongHelp]] format, or you can browse an unofficial [http://www.snowstone.org.uk/riscos/desklib/ online HTML version]. The download also includes various notes and updates which can be accessed from the ''Help'' option on the filer menu for the applications.
-
===Changes Since 2.60===
+
===Tutorials & Examples===
 +
* [http://www.acornusers.org/cbsa/oldversion/Program.html#Desklib2 Tutorial by Frauke Nonnenmacher] (quite old, but still good)
 +
* [http://homepage.ntlworld.com/shaun.lindsley/ Examples by Shaun Lindsley]
-
<ul>
+
==Development Versions==
-
  <li>Fix problematic debugging macro causing branch through zero
+
-
  <li>DeskLib is now entirely built with GCC.  It remains compatible
+
-
  with various combinations of GCC/Norcroft/UnixLib/SharedCLibrary,
+
-
  and problems with varargs have been fixed.
+
-
  <li>All the examples have been checked and brought up to date.
+
-
  <li>Miscellaneous improvements from John Tytgat
+
-
</ul>
+
-
===Changes Since 2.52===
+
===Source===
 +
The sources for DeskLib are held in a [[Source_repositories_overview#DeskLib|subversion repository]] on riscos.info. Read access is available to all, either by checking out the project with svn or by viewing via the [http://www.riscos.info/websvn/listing.php?repname=DeskLib&path=%2F&sc=0 WebSVN] web interface.
-
<ul>
+
To make contributions, post to the DeskLib mailing list with patches or a request for svn write access.
-
  <li>Speed improvements to Wimp_Poll
+
====Properties====
-
  <li>Some missed non 32-bit code now fixed
+
Subversion allows 'properties' to be set for files in the repository and a number of conventions should be followed when creating or modifying files:
-
  <li>Removed RISC OS 2 compatiblity code for Window_GetInfo which was causing problems
+
* <code>svn:executable</code> should be '''unset''' for all files
-
  <li>Corrected Nested Wimp API
+
* <code>svn:mime-type</code> should be set equal to some non-text value (for instance <code>application/octet-stream</code>) for binary files
-
  <li>Added extra wimp flag colours - this may require changes in your code
+
* <code>svn:eol-style</code> should be set to <code>native</code> for all text-based files, and should '''not''' be set for binary files
-
  <li>Import Backtrace functionality from Desk
+
-
</ul>
+
-
===Changes Since 2.50===
+
===Building===
-
 
+
DeskLib is built, as standard, using [[GCCSDK|GCC]], though it should still build using other compilers. To build from the sources either use the [[Using GCCSDK#Using the cross-compiler with Autobuilder|GCCSDK autobuilder]] or, if cross-compiling using GCCSDK:
-
<ul>
+
make -f Makefile.unix
-
  <li>Misc type handling improvements
+
To build the Debugs and SmallError supplementary libraries in addition to the main DeskLib library, use:
-
  <li>Additonal GFX functions for clipping and colour setting
+
make -f Makefile.unix all debugs smerror
-
  <li>Various new Sprite functions
+
<code>Makefile.unix</code> can be found inside <code>!DLSources</code>. (Note: if using a unix environment, don't forget to escape the <code>!</code>s in the RISC OS application names, e.g.: <code>cd \!DLSources</code>.) For the build to be successful, the environment variable <code>GCCSDK_INSTALL_CROSSBIN</code> needs to be present. If you don't have this set already and you've followed the standard installation instructions for GCCSDK then adding the line:
-
  <li>Misc warning fixes in the build
+
GCCSDK_INSTALL_CROSSBIN ?= /home/riscos/cross/bin
-
  <li>Fix register handing in Sprite_GetUser
+
to the start of the makefile will set the variable for you.
-
</ul>
+
-
 
+
-
===Changes Since 2.40===
+
-
 
+
-
<ul>
+
-
  <li>Some new font handling calls - ColourTrans_SetFontColours, Font_GetWimpFont
+
-
  <li>Signedness fixes for string handling
+
-
  <li>Correct termination in icon bar icon
+
-
  <li>Discard old h_doc arrangement, and all associated binaries
+
-
  <li>Added Menu_ForceClose to close open menus
+
-
  <li>Additional use of const where required
+
-
  <li>SaveAs handling messages fix
+
-
  <li>Support for RISC OS 3.5+ Screen modes, and sprite mode specifiers
+
-
  <li>New TaskWindow support
+
-
  <li>Preliminary USB/PCI interface (not implemented)
+
-
  <li>New WimpMsg module - simpler messages
+
-
  <li>New URL module - URI handling
+
-
  <li>Added EventMsg_ReleaseSpecific
+
-
  <li>Added GFX_ReadPoint
+
-
  <li>Make File_Size return -1 on error
+
-
  <li>Fixes and new makefile to allow cross compiling
+
-
  <li>Various MessageTrans fixes
+
-
  <li>Header documentation made consistent
+
-
  <li>Some additions for Nested Wimp
+
-
  <li>Examples supplied with Makefiles suitable for GCC too
+
-
 
+
-
</ul>
+
-
 
+
-
==Getting the source==
+
-
 
+
-
DeskLib source is available via the [[Source_repositories_overview#DeskLib|riscos.info Subversion server]]
+
-
 
+
-
 
+
-
==Documentation==
+
-
[http://www.acornusers.org/cbsa/oldversion/Program.html#Desklib2 Tutorial by Frauke Nonnenmacher] (quite old)
+
Note: version 2.80 may be the last AOF-based release. Version 3 will be ELF-based and will require [[GCCSDK Development|GCC 4.x]].
-
[http://homepage.ntlworld.com/shaun.lindsley/ Examples by Shaun Lindsley]
+
==Support==
 +
If you have questions either about the use of DeskLib or about building it, please either ask on the [http://groups.google.co.uk/group/comp.sys.acorn.programmer/topics?hl=en comp.sys.acorn.programmer usenet group] or the [http://groups.google.co.uk/group/desklib?hl=en DeskLib mailing list]. (The mailing list can be joined by sending an email to [mailto:desklib-subscribe@googlegroups.com desklib-subscribe@googlegroups.com].)

Revision as of 15:28, 2 July 2007

C Wimp Library for RISC OS

Contents

Introduction

DeskLib is a fully-sourced, general-purpose freeware C library for writing desktop applications for RISC OS. It provides comprehensive support for window and icon manipulation, menu creation, graphics routines, message handling, filing operations, font handling, string manipulation and much more. High level event management functions are provided in order to build coherent and powerful code.

Download

Latest Release

The current version of DeskLib is 2.80, released in July 2007. It is made up of three zip files:

  • Core contains everything needed to use the library, including documentation.
  • Source contains the C and assembler source which makes up the library functions.
  • Examples has practical examples on how to use the different parts of DeskLib.

Changes

Changes since version 2.70 include:

  • Several important bugfixes, optimisations and a couple of API changes in Sprite.
  • Provided 'sprite by pointer' in addition to 'sprite by name' routines (named as Sprite_*P()).
  • Added Sprite_SetPointerShape()/Sprite_SetPointerShapeP().
  • Some extra examples
  • Tinct support
  • Rationalised documentation including an updated StrongHelp manual
  • Minor additions to the Icon and Window modules

For older changes, see the changes page.

Documentation

Manuals

Descriptions of the functions, structures, types etc are included with the Core download in StrongHelp format, or you can browse an unofficial online HTML version. The download also includes various notes and updates which can be accessed from the Help option on the filer menu for the applications.

Tutorials & Examples

Development Versions

Source

The sources for DeskLib are held in a subversion repository on riscos.info. Read access is available to all, either by checking out the project with svn or by viewing via the WebSVN web interface.

To make contributions, post to the DeskLib mailing list with patches or a request for svn write access.

Properties

Subversion allows 'properties' to be set for files in the repository and a number of conventions should be followed when creating or modifying files:

  • svn:executable should be unset for all files
  • svn:mime-type should be set equal to some non-text value (for instance application/octet-stream) for binary files
  • svn:eol-style should be set to native for all text-based files, and should not be set for binary files

Building

DeskLib is built, as standard, using GCC, though it should still build using other compilers. To build from the sources either use the GCCSDK autobuilder or, if cross-compiling using GCCSDK:

make -f Makefile.unix

To build the Debugs and SmallError supplementary libraries in addition to the main DeskLib library, use:

make -f Makefile.unix all debugs smerror

Makefile.unix can be found inside !DLSources. (Note: if using a unix environment, don't forget to escape the !s in the RISC OS application names, e.g.: cd \!DLSources.) For the build to be successful, the environment variable GCCSDK_INSTALL_CROSSBIN needs to be present. If you don't have this set already and you've followed the standard installation instructions for GCCSDK then adding the line:

GCCSDK_INSTALL_CROSSBIN ?= /home/riscos/cross/bin

to the start of the makefile will set the variable for you.

Note: version 2.80 may be the last AOF-based release. Version 3 will be ELF-based and will require GCC 4.x.

Support

If you have questions either about the use of DeskLib or about building it, please either ask on the comp.sys.acorn.programmer usenet group or the DeskLib mailing list. (The mailing list can be joined by sending an email to desklib-subscribe@googlegroups.com.)

Personal tools