first element in the array that is matched by match(item, cdata)==True.
- added WMArrayFirst(), WMArrayLast(), WMArrayNext() and WMArrayPrevious()
functions and also WM_ITERATE_ARRAY() and WM_ETARETI_ARRAY() macros, to make
interfaces to WMBag and WMArray similar and to make life a little simpler
when iterating through all elements of an array.
- replaced bags with arrays wherever appropriate. This will improve
performance a bit.
- replaced some recursive code with iterative code in WINGs/selection.c
- some code cleanup is src/
easier to work with it this way.
- better naming of options in the clip options menu.
- better detection of whether to use EXEC or SHEXEC in WPrefs menu editor.
correct switch to it, depending on the value of the DisableDithering option.
- Replaced some functions with macros in WINGs (wmkpoint(), wmksize() and
wmkrange()). They're less expensive to call this way.
- Fixed a memleak in the info panel.
- made the WMRunModalLoop() reentrant (a modal panel can have its own
modal panel and so on) by saving the modal related information when
entering the modal loop and restoring it after.
fixes a memory leak (the window didn't go away because its destroy
function was not actually called. Also non-shaded windows were
unmapped, but not destroyed either, so they just apparently went away).
WMConnection code. do call by yourself wsyserrorwithcode() passing
WCErrorCode, whenever a call don't return the expected value, and
WCErrorCode > 0. If WCErrorCode==0 that is not an system error,
condition, so don't call wsyserrorwithcode() in that case.
- added some assertions where appropriate
connection survives or not an exec* family call. By default all
connections created by WINGs, set the socket to be closed on an exec*
call. Use the function if you need the reverse.
code like
*ptr++ = *ptr++ = *ptr++ = color;
is wrong, because there is no guarantee that ptr will be incremented
_between_ the assignment operations. it can be incremented after all
assignment operations as well. Because of this both of these are valid
implementations for a compiler:
a. assign, increment, assign, increment, assign, increment
b. assign, assign, assign, increment by 3
In case b. only the first memory location of the 3 will be modified, being
assigned 3 times the same value, while the other 2 remain unchanged.
For example egcs-2.91.66 (and possibly gcc-2.95.x too) implement this in
the second way (like in case b.)
Also the order in which the assignement is made is undefined (left to right
or right to left).
this fixed the problem we had with greyscale jpegs showing up in red,
and possibly other problems related to pseudocolor and greyscale displays.
written in the libwraster.la file allowing automatic linking against
all the libs libwraster depends upon without specifing them again when
linking programs that use libwraster. -lwraster will be enough.
old one (the one renamed to wstrconcat). The new wstrappend(dst, src)
will modify and return dst, without creating a new string to hold the
result, except if dst==NULL, in which case its equivalent to calling
wstrdup(src)
be sure to replace wstrappend() with wstrconcat() anywhere in your code
because a new wstrappend() function will be implemented that will have
different semantics and if your code will use the new one instead of
the old will break.