- Finished moving to the new proplist handling code in WINGs.
[wmaker-crm.git] / WINGs / NEWS
blob5915814ff410830ec303f0507b22bb8121551e59
2 *** Thu Oct 04 06:00:09 EEST 2001 -Dan
4 Property lists handling code
5 ----------------------------
7 Code to handle property lists was added to WINGs. It is more robust
8 than the libPropList code, mostly because some conflicting concepts 
9 borrowed from UserDefaults (which libPropList uses) are no longer used in
10 the property lists code.
11 It is also better integrated with the other data types from WINGs.
13 Old libPropList based code can still run with the new WINGs proplist
14 code with minimal changes which are described in detail in the comments
15 at the top of the WINGs/proplist-compat.h header file (the same file
16 carries the #defines for mapping old libPropList functions to the new
17 WINGs proplist functions).
20 *** Sat Apr 21 09:12:09 EEST 2001 -Dan
22 API change
23 ----------
25 To allow a correct display of icon images with alpha blending in panels and
26 other places where a WINGs based application may use them the following
27 changes took place:
29 1. The following functions were renamed:
30    - WMSetApplicationIconImage()  --> WMSetApplicationIconPixmap()
31    - WMGetApplicationIconImage()  --> WMGetApplicationIconPixmap()
32    - WMSetWindowMiniwindowImage() --> WMSetWindowMiniwindowPixmap()
33 2. The following functions were added:
34    - WMSetApplicationIconImage(WMScreen *scr, RImage *image)
35    - RImage* WMGetApplicationIconImage(WMScreen *scr)
36    - WMPixmap* WMCreateApplicationIconBlendedPixmap(WMScreen *scr, RColor *col)
38 As you can see the old functions that operated on WMPixmap images (which are
39 basically X Pixmaps that lack alpha information) were renamed to ...Pixmap()
40 to make them more suggestive about what they do and to make room for the
41 new functions that operate on RImages (that hold alpha information).
43 Since the corresponding WMGet... functions only retrieve the stored
44 image/pixmap from the application, I'll outline how the WMSet...
45 functions operate:
47 All WM...IconPixmap() functions operate on WMPixmaps
48 All WM...IconImage() functions operate on RImages
51 - WMSetApplicationIconImage() will set the RImage to be used in panels
52     and will also convert the RImage to a WMPixmap with a threshold of 128
53     and will use that pixmap for the appicon image. If that doesn't satisfy
54     you, you can make a call to WMSetApplicationIconPixmap() on your own to
55     set whatever WMPixmap you see fit for the appicon. 
57 - WMSetApplicationIconPixmap() will set the WMPixmap to be used for the
58     appicon and for the panels 
61 If you use only one of the above functions, the corresponding image/pixmap
62 will be used everywhere where needed (panels and appicon), but the pixmap
63 version will not be able to handle alpha blending correctly.
65 If you use both WMSetApplicationIconImage() and WMSetApplicationIconPixmap()
66 then the RImage will have priority in panels, and the WMPixmap will only be
67 used for the appicon. This allows you to better control what icon is
68 displayed in the appicon, in case the default conversion of the RImage to a
69 pixmap with a threshold of 128 is not good enough, or in case you want a
70 different icon to be shown in the appicon than in panels.
73 Also this new function was added:
75 - WMCreateApplicationIconBlendedPixmap() will use the RImage set with
76     WMSetApplicationIconImage() if available and will blend it with the color
77     you passed. This will make the image show well on a background of that
78     color. If the RImage was not set it will return NULL. You need to call
79     WMReleasePixmap() on it after you finish with it. Passing a NULL pointer
80     instead of a color will make the RImage be blended with the default color
81     of the WINGs widgets: '#aeaaae' making it suitable to be assigned to any
82     WINGs widget.
85 To make your existing code work as before all you need to do is to rename
86 the following functions:
88    - WMSetApplicationIconImage()  --> WMSetApplicationIconPixmap()
89    - WMGetApplicationIconImage()  --> WMGetApplicationIconPixmap()
90    - WMSetWindowMiniwindowImage() --> WMSetWindowMiniwindowPixmap()
92 But if you want to take advantage of the new abilities to show alpha
93 blended images you need to start using the new functions.