As reported by Coverity, the return value for XGetWindowAttributes is
usually checked in many places, because it is a good practice to ensure
that it did work, but it was not checked when called in the function
'wClientCheckProperty'.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
As pointed by Coverity, the return value is saved into a variable, but this
value is never used. As the variable is re-used afterwards, this
assignation could mislead on what is done, so for code maintainability the
value is just ignored.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
Signed-off-by: Carlos R. Mafra <crmafra@gmail.com>
The usual way to define a macro in is to name macro with 'USE_xxx' when
they are used to enable a feature 'xxx'
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
If a window handles a ConfigureRequest which did not specify a move or
resize operation we should not call wWindowConfigure() and save the
window geometry.
Sergey Popov reported a scenario in which the old behaviour caused a bug:
* Start gvim with a server.
"gvim --servername qwe .gimvrc"
* Maximize gvim.
* (Re)open a file in the same window
"gvim --servername qwe --remote-silent .gvimrc"
* Now the window claims to be unmaximized and its old geometry is
forgotten.
The bug was that when the gvim window reread the file it generated a
ConfigureRequest without specifying a geometry change but we called
wWindowConfigure() and saved its geometry as though it had been
maximized.
The function wIconChangeTitle() now changes the icon title name
doing the full work (except painting it).
The function receives now the icon to change the name and the
wwindow with the new name. The function checks if icon and the
window exists.
Then, try to get the name using wNETWMGetIconName(), if not found
then try to read it from wGetIconName(). Then the icon has the new
name and the function returns.
This is better because:
1. We don't need a flag to know if the window got the name
using the wNETWMGetIconName function. Now call this function
always.
2. We do the same work in all calls to the wIconChangeTitle()
function.
The functions that uses wIconChangeTitle (at client.c, icon.c and
wmspec.c) uses always the value set by wNETWMGetIconName() first,
else, the value set by wGetIconName(). This is the reason for the
flag net_has_icon_title. Now the flag can be removed.
The function wIconUpdate can receive a image to setup as icon image.
If image is NULL, then use the original method, using different procedures
to get the image.
Windows were drifting by FRAME_BORDER_WIDTH pixels when their
borders were toggled on or off.
Windows which had a border before we managed them were drifting
on shutdown and again at startup. It happened because the absolute
upper-left co-ordinates of a bordered window would in fact be the
upper-left co-ordinates of the border itself, whereas we consider
the client window to have no border and co-ordinates offset by the
titlebar and frame border.
The initial fix for the bug reported by Paul Seelig whereby windows
would drift on restart introduced two regressions.
New windows would place higher on the screen than intended, possibly
obscuring the bottoms of other windows with their titlebars, and all
windows would jump vertically at shutdown because we weren't restoring
them to where they were before they had a titlebar and border.
The functions related to colormap are moved from funcs.h to the new
file colormap.h. These files are included where needed.
The functions wColormapInstallRoot and wColormapUninstallRoot are
removed, because they are not used.
The rationale is the same as in commit c7f2a189c4
("Fix the call to XChangeProperty() in 64-bit mode"), because we are
calling XChangeProperty() with format 32, which requires the type of
'data' to be 'long'.
When a maximized window is resized (either using wmaker or because the
application changed the window size), and you want to maximize it again,
you first have to unmaximize it (because wmaker thinks the window is still
maximized), and only then you can maximize it. The following patch
corrects this behaviour.
for arq in `git ls-files *.c`; do
echo $arq;
indent -linux -l115 $arq;
done
The different line break at 115 columns is because
I use a widescreen monitor :-)
- Fixed bug in icon chooser dialog that could cause a segmentation fault
in some cases (Pascal Hofstee <caelian@gmail.com>)
- Fixed crash in asm code in wrlib, with new versions of gcc.
- Fixed bug in the x86_PseudoColor_32_to_8() function which incorrectly
used the r, g, b fields in the conversion.
- Fixed x86 ASM code in wrlib to work on 64 bit architectures.
- Fixed the focus flicker seen with some apps (notably gtk2)
(Alexey Spiridonov <snarkmaster@gmail.com>)
- Fixed all crashing bugs that were generated by wmaker starting with the
WMState file missing.
- Added NetWM support (a modified version of the patch originaly written
by Peter Zijlstra <a.p.zijlstra@chello.nl>)
- Applied patch to enhance the Virtual Desktop behaviour, and to integrate
it with the NetWM code (Peter Zijlstra <a.p.zijlstra@chello.nl>)
- Applied a few xinerama and placement fixes (Peter Zijlstra
<a.p.zijlstra@chello.nl>)
- Fixed memory leak in dock code.
- Fixed and enhanced the text wrapping in WINGs.
- Fixed the layout of some elements in WPrefs.app
- Added workaround for aplications that don't set the required hints on the
client leader window, but they set them on normal windows (observer with
KDE 3.3.0 mainly). This will allow these apps to get an appicon again.
(they should be fixed still)
- Added workaround for applications that do not set a command with
XSetCommand(), but instead they set the _NET_WM_PID property. This works
with operating systems that offer a /proc interface similar to what linux
has. (This also is to fix problems with KDE 3.3.0 apps, but not only them).
- Fixed bug with autostart and exit scripts not being executed if user
GNUstep path was different from ~/GNUstep (when setting GNUSTEP_USER_ROOT)
- Added utf8 support in WINGs (removed old X core font code)
- Added utility to convert old font names to new font names in style files
- Separated the font caches for normal fonts and fontsets in WINGs (they can
have the same names and collide in the cache giving unwanted results)
- Updated the years in the copyright notices
is created after the application has mapped its window(s).
This means that if you use wterm without an appmenu it will be able to
use shared appicons, but as soon as you start one with an appmenu they
will get separated appicons.