DeskLib: Difference between revisions
m (Reverted edit of GwzEgs, changed back to last version by Adamr) |
(New page to go with new release) |
||
Line 1: | Line 1: | ||
= |
''<font size=+1>C Wimp Library for RISC OS</font>'' |
||
==Introduction== |
|||
===Development Versions=== |
|||
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. |
|||
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]]. |
|||
==Download== |
|||
===7th May 2005 - DeskLib 2.70 release=== |
|||
===Latest Release=== |
|||
This version is 32-bit, and only suitable for compiling and linking with 32-bit compilers and libraries. DeskLib has been carefully designed |
|||
The current version of DeskLib is 2.80, released in July 2007. It is made up of three zip files: |
|||
to work properly with almost all combinations of RISC OS compilers and C libraries. |
|||
*[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. |
|||
===Changes=== |
|||
For more information about 32-bit, see [[32bit|RISC OS and 32-bit]] |
|||
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 [[DeskLib Changes|changes]] page. |
|||
DeskLib 2.70 can be downloaded from the [http://www.riscos.info/downloads/DeskLib-2.70/ downloads] section. |
|||
== |
==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. |
|||
=== |
===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] |
|||
==Development Versions== |
|||
<ul> |
|||
<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> |
|||
=== |
===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. |
|||
To make contributions, post to the DeskLib mailing list with patches or a request for svn write access. |
|||
<ul> |
|||
====Properties==== |
|||
<li>Speed improvements to Wimp_Poll |
|||
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>Some missed non 32-bit code now fixed |
|||
* <code>svn:executable</code> should be '''unset''' for all files |
|||
<li>Removed RISC OS 2 compatiblity code for Window_GetInfo which was causing problems |
|||
* <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>Corrected Nested Wimp API |
|||
* <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>Added extra wimp flag colours - this may require changes in your code |
|||
<li>Import Backtrace functionality from Desk |
|||
</ul> |
|||
=== |
===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: |
|||
make -f Makefile.unix |
|||
<ul> |
|||
To build the Debugs and SmallError supplementary libraries in addition to the main DeskLib library, use: |
|||
<li>Misc type handling improvements |
|||
make -f Makefile.unix all debugs smerror |
|||
<li>Additonal GFX functions for clipping and colour setting |
|||
<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>Various new Sprite functions |
|||
GCCSDK_INSTALL_CROSSBIN ?= /home/riscos/cross/bin |
|||
<li>Misc warning fixes in the build |
|||
to the start of the makefile will set the variable for you. |
|||
<li>Fix register handing in Sprite_GetUser |
|||
</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== |
|||
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://www.acornusers.org/cbsa/oldversion/Program.html#Desklib2 Tutorial by Frauke Nonnenmacher] (quite old) |
|||
==Support== |
|||
[http://homepage.ntlworld.com/shaun.lindsley/ Examples by Shaun Lindsley] |
|||
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
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
- Tutorial by Frauke Nonnenmacher (quite old, but still good)
- Examples by Shaun Lindsley
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 filessvn:mime-type
should be set equal to some non-text value (for instanceapplication/octet-stream
) for binary filessvn:eol-style
should be set tonative
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.)