[futurebasic] Beginner: Plot Icons

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : January 2010 : Group Archive : Group : All Groups

From: Ken Shmidheiser <kshmidheiser@...>
Date: Sat, 30 Jan 2010 02:05:04 -0500
Emmett asked:

>I have been unable to find any further reference to the concept of plot icons.
>Can someone expand on the meaning?

Emmett:

Icons can be drawn or "plotted" to a window just like a picture. But 
as the FB warning states. Picture On/Picture Off does not work with 
an icon as it does with other drawings.

Ken

// Demo: Plot the Trash Full icon to a window

include "Tlbx Icons.incl"

dim as IconRef  trashIcon
dim as Rect     r
dim as OSErr    err

SetRect( r, 0, 0, 120, 120 )
window 1,"Trash",@r

err = fn GetIconRef( _kOnSystemDisk, _kSystemIconsCreator, 
_kFullTrashIcon, trashIcon )
long if ( err == _noErr )
SetRect( r, 20, 20, 100, 100 )
err = fn PlotIconRef ( r, _kAlignAbsoluteCenter, _kTransformNone, 
_kIconServicesNormalUsageFlag, trashIcon )
end if

do
HandleEvents
until gFBQuit