
WinampSkin Delphi Component
---------------------------

Version 0.1b

Copyright (C) 1999 Francois.Zbinden@djus.ch

This program 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
of the License, or (at your option) any later version.

This program 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 this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.


INSTALL
-------

Tested on Delphi 3+4. It will _not_ work on Delphi 5, see below!

Click Component|Install. Search the file winampskin.pas included in this
package (if not get your free copy at http://eclipse.djus.ch/winampskin)
and compile dclusr50.dpk. Now there should be a new component in the register 'Freeware'.

Note: This is a beta version!

If you have found a bug please send a report to winampskin-bugs@djus.ch.

You will find the newest version and a bug report tool at http://eclipse.djus.ch/winampskin.


IMPORTANT FOR DELPHI 5
----------------------

There is a bug in Delphi 5. It produces a stream read error on component insert!
Try this fix from <david@intellex.demon.co.uk.nospam>

     In graphics.pas in TBitmap.ReadDIB there is a bug in the following line:
         RLEStream.Seek(ImageSize, soFromEnd);
     It should in fact be
         RLEStream.Seek(-ImageSize, soFromEnd);
     i.e. a negative number for the seek.



METHODS AND PROPERTIES
----------------------

Load a skin from downloaded Winamp skin from a specified directory.
	function LoadFromDirectory(Directory:string):integer;

Load standard skin included in components resource
	function LoadFromResource:integer;

If the volume or balance changes
	property OnVolumeChange: TVolumeChangeEvent
	property OnBalanceChange: TBalanceChangeEvent

One of the button was pressed
        property OnPlayClick: TNotifyEvent
        property OnStopClick: TNotifyEvent
        property OnPauseClick: TNotifyEvent
        property OnForwardClick: TNotifyEvent
        property OnBackClick: TNotifyEvent
        property OnEjectClick: TNotifyEvent

Raised if one of this small button was pressed
        property OnPlaylistClick: TCheckedEvent
        property OnEqualizerClick: TCheckedEvent

The tree buttons in title bar. the minimize button minimize the application
and don't raise any event!
	property OnCloseClick: TNotifyEvent
	property OnSticky: TStickyEvent
	property OnMenuClick:  TNotifyEvent

If the PositionBar is moved by user
	property OnPositionChange: TPositionEvent

If you (re-)load the skin
	property OnSkinChanged: TNotifyEvent

Here you can say witch checkboxes are on (green) or off
	property Checked: TSkinChecked read FChecked write SetChecked;

Volume range is from 0 to 100. Balance too, but 50 is center!
	property Volume:integer read FVolume write SetVolume default 80;
	property Balance: integer read FBalance write SetBalance default 50;

Text in the scrolling text area (mostly song title)
  	property Title: string read FTitle write SetTitle;

Component is Sticky
    	property Sticky: boolean read FSticky write SetSticky;

Status and ready changes the small stop, play or pause bitmap in the top left corner
    	property Status:TStatus read FStatus write SetStatus;
	property Ready:boolean read FReady write SetReady;

Bitrate of the song (example 128)
	property Bitrate:integer read FBitrate write SetBitrate;

If you want to have 44 in the frequency box, set the value to 44000
	property Frequency:integer read FFrequency write SetFrequency;

Here you can control the Mono/Stereo "leds"
    	property StereoMode:TStereoMode read FStereoMode write SetStereoMode;

The values for the pseudo Vu-Meter. This is the only thing not similar to
Winamp. But the colors for this are taken from Viscolor.txt
    	property LeftMeter:byte read FLeftMeter write SetLeftMeter;
	property RightMeter:byte read FRightMeter write SetRightMeter;

Set this to false if you application doesn't have the focus
    	property Active:boolean read FActive write SetActive;

Position bar position :) -1 is disabled
    	property PositionBar:integer read FPositionBar write SetPositionBar;

Set this to false if you don't want to allow to move the position by user
	property PosBarMove:boolean read FPosBarMove write FPosBarMove default true;

The time of the song or whatever, you have to give someting like this: '01:21'
        property Progress:string read FProgress write SetProgress;

Set if you want to have custom cursors from skin and auto use this
        property AutoCursor:boolean read FAutoCursor write FAutoCursor default true;




HOW TO MAKE YOUR OWN RESOURCE FROM A SKIN
-----------------------------------------

Because of palette problems in the Image Editor, we need to compile this by
hand using the command line resource compiler.
Look at the winampskin.rc file. You have to put in the files from your skin
there. Then open a command shell, go into your Winampskin directory and
start the compiler:

  brcc32 _winampskin.rc

Then rename the created _winampskin.res to _winampskin.dcr and recompile the
component.



