unit IconsIncluder; { [IconsIncluder] [1.0] Delphi 2005 February 2007 LICENSE The contents of this file are subject to the Mozilla Public License Version 1.1 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at "http://www.mozilla.org/MPL/" Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. The Original Code is "[IconsIncluder.pas] and [IconsIncluder.dfm]". The Initial Developer of the Original Code is Martin Holmes (Victoria, BC, Canada, "http://www.mholmes.com/"). Copyright (C) 2005 Martin Holmes and the University of Victoria Computing and Media Centre. The code was co-developed for university and personal projects, and rights are shared by Martin Holmes and the University of Victoria. All Rights Reserved. } { Written by Martin Holmes, Spring 2007. The purpose of this unit is to make it possible to comply with the terms of the Lesser GNU Public Licence for the Nuvola icon set, by David Vignoni. In order to use LGLP code in a commercial or non-open-source project, the code for the library must be released, and it must be included in the project in a library form such that anyone can replace or modify it as they wish. The Nuvola icons in the related icons.pas file, compiled into nuvola.dll, are included in twelve image lists; those image lists are mapped to image lists in this form (IconsIncluder.pas/dfm), which can then be used by the project in the normal way. (Thanks to Doni Devito for showing me this technique.) The nuvola.dll library is available for use in other projects, and can be replaced with a modified version in any project which includes it. Dependencies: nuvola.dll (compiled from nuvola.dpr and icons.pas). } interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, ImgList; function Fnc_Img16Normal: integer; stdcall; function Fnc_Img16Disabled: integer; stdcall; function Fnc_Img16Hot: integer; stdcall; function Fnc_Img24Normal: integer; stdcall; function Fnc_Img24Disabled: integer; stdcall; function Fnc_Img24Hot: integer; stdcall; function Fnc_Img32Normal: integer; stdcall; function Fnc_Img32Disabled: integer; stdcall; function Fnc_Img32Hot: integer; stdcall; function Fnc_Img48Normal: integer; stdcall; function Fnc_Img48Disabled: integer; stdcall; function Fnc_Img48Hot: integer; stdcall; type TIconsInc = class(TForm) il16_Normal: TImageList; il16_Disabled: TImageList; il16_Hot: TImageList; il24_Normal: TImageList; il24_Disabled: TImageList; il24_Hot: TImageList; il32_Normal: TImageList; il32_Disabled: TImageList; il32_Hot: TImageList; il48_Normal: TImageList; il48_Disabled: TImageList; il48_Hot: TImageList; procedure FormCreate(Sender: TObject); private { Private declarations } public { Public declarations } end; var IconsInc: TIconsInc; implementation {$R *.dfm} function Fnc_Img16Normal: integer; external 'nuvola.dll'; function Fnc_Img16Disabled: integer; external 'nuvola.dll'; function Fnc_Img16Hot: integer; external 'nuvola.dll'; function Fnc_Img24Normal: integer; external 'nuvola.dll'; function Fnc_Img24Disabled: integer; external 'nuvola.dll'; function Fnc_Img24Hot: integer; external 'nuvola.dll'; function Fnc_Img32Normal: integer; external 'nuvola.dll'; function Fnc_Img32Disabled: integer; external 'nuvola.dll'; function Fnc_Img32Hot: integer; external 'nuvola.dll'; function Fnc_Img48Normal: integer; external 'nuvola.dll'; function Fnc_Img48Disabled: integer; external 'nuvola.dll'; function Fnc_Img48Hot: integer; external 'nuvola.dll'; procedure TIconsInc.FormCreate(Sender: TObject); begin il16_Normal.Handle := Fnc_Img16Normal; il16_Disabled.Handle := Fnc_Img16Disabled; il16_Hot.Handle := Fnc_Img16Hot; il24_Normal.Handle := Fnc_Img24Normal; il24_Disabled.Handle := Fnc_Img24Disabled; il24_Hot.Handle := Fnc_Img24Hot; il32_Normal.Handle := Fnc_Img32Normal; il32_Disabled.Handle := Fnc_Img32Disabled; il32_Hot.Handle := Fnc_Img32Hot; il48_Normal.Handle := Fnc_Img48Normal; il48_Disabled.Handle := Fnc_Img48Disabled; il48_Hot.Handle := Fnc_Img48Hot; end; end.