Animated cursor (ANI) files
ANI files are collections of CUR image files with timing and
sequencing information that describe how the images are to be displayed.
When browsing these files with the IconPainter file chooser, the
first image found in the file is displayed in the chooser window.
Creating and editing an ANI file
To create a new ANI file choose the ANI file format from the list of available file formats when saving a newly
created image. The IconPainter
ANI editing dialog will appear which will allow the various parameters of the ANI file to be set. Settings changed in
this dialog are only changed when the "Save" button is pushed.
To add new frames press the "Add" button and normal IconPainter editing mode will resume.
When a subsequent "Save" is then invoked the ANI dialog will reappear with the new image appended.
Existing frames can be similarly edited by selecting an existing frame by clicking on it and then pressing the
"Save" button.
Deleting a frame
Any frame in the file can be deleted by clicking on it and then pressing the "Delete"
button. The frame is removed and if a sequence is defined then that frame is removed from the
sequence as well as being removed from the list of rates if there is one. The blits are
also reset to be the number of remaining frames (or steps in the sequence if defined).
Internal data
These two text fields are optional and will be stored inside the ANI file to identify it's
origins. The "name" filed is typically the name assigned to the icon while the "artist" field is used
to store the artist's name or copyright owner. There is no restriction on the length of these fields,
if they exceed the size of fields that IconPainter displays it doesn't matter. If the name field is left
blank but the artist field is entered IconPainter will not save the artist field on it's own.
Setting the sequence
If the sequence is not set then the sequence list will display "Empty" and the sequence will be the default which is
going from frame 1 to 2 to 3 etc and then cycling back to frame 1. If another sequence is desired then press "Define"
and the sequence setting dialog will appear. Frames are added to the sequence by clicking on them. There is no limit
to the number of frames in the sequence and the same frame may appear as many times as you like in the sequence.
Like all changes to the animation, IconPainter will show the new sequence in it's animation as soon as it is defined.
The rate of animation
The overall delay for each frame can be controlled by the individual rate value
shown on the right of the edit dialog. However it's also possible
to create a list of individual rates for each frame. If both a non-zero single rate
value AND a list of rates are specified then windows adds the single rate value to
the individual rate value to get the total delay for the frame. All delay values are in
units of a "Jiffie" which is one sixtieth of a second.
The number of blits
The number of blits makes no difference to the animation displayed by IconPainter when
editing an ANI file. Normally the number of blits is the same as the number of frames (or the number of the
number if steps in the sequnce if set)
and this is a safe number to use
but Windows can be instructed to blit at a different rate to this. Since an inapproprate number of
blits will cause a fatal error in Windows, IconPainter will always reset this number to
the number of frames (or the number of sequence entries) when a frame is added. The user should know what they're doing
when they change this number and do so entirely at their own risk.
The X hotspot and Y hotspot
Just like a Windows cursor, an animated cursor has a single hotspot which is the same
for all frames in the animation. This defaults to (0,0) unless set.
Creating strips
It's often useful to have a single strip image of all the images in an ANI file as a single strip image. This allows
animation by other software such as a Java applet.
The background color
There is no background color for ANI files however IconPainter uses the current
background color to display the ANI images. It's best to choose a background color
which is typical of the kind of background over which the cursor will appear while at the
same time it's important to choose a color that does not appear in the images themselves.
Extended ANI files
In Windows98 amongst the desktop themes there are 3 or 4 Microsoft authored ANI files that use an extended version
of the standard ANI format. These files differ in one or more of the following ways:
- Have non-standard sizes eg.34x34
- Are not square eg.38x41
- Save information in 24-bit format.
At this time IconPainter doesn't support these extensions. It's anticipated support will be included in a future version.
Additionally there exists some other non-Microsoft ANI files that contain more than one image for each frame of the
animation, for these files IconPainter reads only the first image found for each frame.