/**************************************************************************** * This source file was written by Acorn Computers Limited. It is part of * * the RISCOS library for writing applications in C for RISC OS. It may be * * used freely in the creation of programs for Archimedes. It should be * * used with Acorn's C Compiler Release 3 or later. * * * ***************************************************************************/ /*----- Licensing note ----------------------------------------------------* * * This file is part of Straylight's Steel library. * * Steel is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2, or (at your option) * any later version. * * Steel is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with Steel. If not, write to the Free Software Foundation, * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ /* * Title: fileicon.h * Purpose: general display of a file icon in a window. * */ # ifndef __fileicon_h # define __fileicon_h # ifndef __wimp_h # include "wimp.h" # endif /* * char *fileicon_spriteName(int filetype,char *name) * * Use * Returns the name of the sprite required to display the file whose name is given. * * Parameters * int filetype == the type of the file * char *name == the name of the file (may be full pathname) * * Returns * Pointer to read-only string. */ char *fileicon_spriteName(int filetype,char *name); /* ------------------------------ fileicon --------------------------------- * Description: Display an icon representing a file, in a given window * * Parameters: wimp_w -- the given window's handle * wimp_i -- an existing icon * int filetype -- RISC OS file type (eg. 0x0ffe) * char *name -- the name of the file (may be pathname) * Returns: void. * Other Info: If you want a file icon in a dialogue box then pass that * dialogue box's window handle through first parameter, * eg fileicon((wimp_w)dbox_syshandle(d),........) * The second parameter is the icon number of the required * icon, within the template set up using FormEd * For an example see the fileInfo template for !Edit. * */ void fileicon(wimp_w, wimp_i, int filetype,char *name); #endif /* end fileicon.h */