This patch adds a new Central feature under the window menu
"Other maximization" entry.
Shortcut can be configured via WPrefs "Center active window" action.
When called the active window is centered on the screen head.
If the window height or width are bigger than the head size,
the window is resized to fit.
There are some transitions defined as below:
*from fullscreen to center
*from any corner to center
*from top half to center top half
*from bottom half to center bottom half
*from left half to center left half
*from right half to center right half
Undoing the action is done via the window menu "Unmaximize" entry
or the shortcut.
That patch is fixing some Actions entries that are not sorted properly.
One is using some upper/lower cases.
And the other one, is displaying numbers while alphabetic sorting is not
working properly on numbers. For example:
Shortcut for window 1
Shortcut for window 10
Shortcut for window 2
...
Align the old maximization descriptions to the new visual indicator
names. The internal shortcut names had also been updated, meaning a
reconfiguration of the shortcuts in WPrefs is required.
This patch adds a feature to take screenshots directly from Window Maker.
Having the feature embeded direclty inside Window Maker allows us to take
advantage of how Window Maker is managing and handling Windows.
Three new actions can be bound to a key shortcut from WPrefs.
The screenshot files are saved in ~/GNUstep/Library/WindowMaker/Screenshots/
dir, with a "screenshot_%Y-%m-%d_at_%H:%M:%S" format followed by the
extension. Preferably as a PNG or JPG file if available.
Meaning, to work Window Maker via WRaster needs to support
at least one of those format.
"Capture the entire screen" is quite standard, it takes a screenshot
of the whole screen area (even in multiheads env).
"Capture a portion of the screen" requires the user to draw a rectangle which
will be captured.
Those two first are quite straightforward, just taking a live picture of
the screen.
The last one is "Capture a window" which works in best effort mode,
it catures the focused window. As Window Maker by default is not using
any compositor (like for example Xcompmgr) it can only dump the content
displayed on the screen.
If a window is minimized or out of the screen, there is high chance the
image will be split or some area greyed in case other windows overlapped it.
Window Maker allows to perform practically all operations with windows
using only keyboard. One of the actions so far which required using
mouse was dragging window from one head (monitor) to another.
This patch introduces support for keyboard shortcuts. These shortcuts
move windows in circular fashion (if you have 3 and more monitors).
In case of 2 or 3 monitors arranged horizontally - window will just move
right/left.
In case of 3x3 setup - it is impossible to move window to central
monitor with keyboard.
- preserves window position and size (if display sizes are same)
- otherwise tries to fit window to smaller display
This patch is adding a checkbox in the expert zone to disable
completely the workspace pager and add an entry in keyshortcut
preference to set the shortcut used to open the pager with the
action "Open workspace pager".
The default frame background can be configured by setting an optional
variable "WorkspaceMapBack" from WindowMaker conf file as in:
WorkspaceMapBack = (tpixmap, "/tmp/testme.png", gray20);
or
WorkspaceMapBack = (solid, "#2c2482");
As pointed by Coverity, if the Keysym name is very long and many modifiers
are used, the function 'capture_shortcut' could overflow its internal
buffer.
As the case is very unlikely to appear, do not increase the size of the internal
buffer (it seems to be already well sized, and we have no know maximum size
for a Keysym name), just use the appropriate function to append the name
at the end.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
Signed-off-by: Carlos R. Mafra <crmafra@gmail.com>
The goal was to reduce the risk of truncated lines in the list of actions
(a few of them are a bit long - and need to be!), so it was an opportunity
to align the widgets with consistent spacing.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This patch is used to fix the Debian bug #140181
It updates the NumLockMask function to report the mask and
call XFreeModifiermap when needed.
It also modifies capture_shortcut function to be able to use Super keys
and report numeric keypad when pressed (aka now detects correctly
if the numlock is enabled or not).
A common feature in several desktop environments is the ability to bring up
a "run application" dialog via a keyboard shortcut (frequently Mod1+F2). This
feature has been available to Window Maker users only through the root menu.
This patch adds the ability for a user to set up a keyboard shortcut to
accomplish this, either via WPrefs or by editing ~/GNUstep/Defaults/WindowMaker,
e.g., with
RunKey = "Mod1+F2";
Code from the execCommand function in rootmenu.c has been copied almost directly
into the handleKeyPress function in misc.c to accomplish this.
The new macro 'wlengthof' from WUtil makes code easier to read than the
previous [sizeof() / sizeof([0]) ] construct.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The functions that create the different configuration panels were taking
the screen structure as argument, but it turns out that none of them
actually need it.
We just remove the argument to make code simpler and easier to maintain.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The WINGs toolkit dispatch events on widgets using callbacks, which means
having a fixed argument list for the handling function.
It is then correct to not use all the arguments, so this patch adds the
appropriate stuff to avoid a false report from compiler.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The mechanism of Notifications in the WINGs toolkit is relying on
callbacks to dispatch notifications, which means having a fixed argument
list for the handling function.
It is then correct to not use all the arguments, so this patch adds the
appropriate stuff to avoid a false report from compiler.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This patch includes the function "NumLockMask", that checks if the
Alt Modifier key is "NumLock". Then we can use this function in the
calls to Capture the key sequence and don't use this modifier.
To ensure proper behaviour with X servers that do not support the
Xkb extension, implemented call to the fall-back legacy function
to the other places where it is being used, to ensure proper
behaviour in any case.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The config-file-keyword was defined in an array, but the user displayed
string was defined at another place, thus requiring special care when
modifying the list, to keep the same number of entries, in the same
order, ...
This was an open call for subtle bugs, so the keyword and user string
are now at a single place, making updates on the list easier and the
GUI generation code smaller.
Added MoveToWorkspace*Key, MoveToNextWorkspaceKey,
MoveToPrevWorkspaceKey, MoveToLastWorkspaceKey,
MoveToNextWorkspaceLayerKey and MoveToPrevWorkspaceLayerKey to the
keyboard shortcut panel of WPrefs.
memset is the last function call in wmalloc, just before it returns the
newly allocated memory. Therefore it is not needed to call it again
after wmalloc call. Although I would prefer to switch wmalloc to a
calloc-based wcalloc function, the compatibility of WINGs for old apps
should be kept.
Use the WindowRelaunchKey shortcut to examine the WM_COMMAND property of
the active application's main window and launch a new instance of the
application using the retrieved command line.
The function captureShortcut() is implemented in both files KeyboardShortcuts.c
and Menu.c, with just a minor difference regarding the conversion to upper case.
To unify them, define a new function which includes a new boolean paramenter to
dictate whether the upper case conversion should be done or not.
There's no need to have a private function while there's one in WINGs.
Besides that, it does not remove trailing whitespaces appropriately as I
just tested by adding trailing space in the shortcut captured by WPrefs.
It is not trimmed before saving it:
[mafra@Pilar:Defaults]$ grep CloseKey WindowMaker
CloseKey = "Mod1+C ";
Using wtrimspace() fixes that and even saves 208 bytes of code:
[mafra@Pilar:WPrefs.app]$ size KeyboardShortcuts.o.*
text data bss dec hex filename
7703 0 0 7703 1e17 KeyboardShortcuts.o.new
7911 0 0 7911 1ee7 KeyboardShortcuts.o.old
Signed-off-by: Carlos R. Mafra <crmafra@gmail.com>
Even the option to enable "virtual desktop" in configure.ac was
commented out...and I would never intend to use it anyway.
So let's just remove the ~800 lines of #ifdef'ed code to have a
cleaner code base to read when bored.
The raising and lowering of the clip is already taken care of
by the "ClipRaiseLowerKey" shortcut.
wmaker gets a bit smaller for free:
text data bss dec hex filename
449483 17384 8208 475075 73fc3 src/.libs/wmaker.old
449307 17256 8192 474755 73e83 src/.libs/wmaker.new
This patch adds the DockRaiseLowerKey shortcut, which raises/lowers
the dock depending on whether the dock is lowered/raised.
[crmafra: Reformatted Brad's patch against git repo and removed the
DockRaiseKey and DockLowerKey shortcuts ]
For those not familiar with the way Macs cycle windows, the Command-Tab
sequence (Alt-Tab elsewhere) switches between DIFFERENT application windows
and Command-Grave (key above tab) switches between windows owned by the
SAME application as is currently focused. So if you had three Safari and
two Finder windows open, and Safari had focus, Command-Tab would switch to
Finder; Command-Tab would switch back to Safari; Command-Grave would switch
to a different Safari window etc.
This patch implements "something like" the above by only populating the
switchpanel with windows matching the currently-focused WWindow's wm_class
when the new cycling mode is activated. In practice this means you can
switch to The Next XTerm or The Next Firefox Window using this method.
The configuration names for these new shortcuts are GroupNext and
GroupPrev. The patch tells WPrefs.app about them. Of course switching to
The Next Window is still possible with the (unchanged) FocusNext and
FocusPrev keys.
This adds Left Half / Right Half Maximize capability to WindowMaker.
It allows you to maximize a window to only the left or right half
of your screen.
It is useful on widescreen displays where one might to bring up
two different windows side-by-side.
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
are affected. Fixes for old code too.
- Double buffering in WMList. All widgets or apps using WMList and
having user drawing porcedures in place will inherit this double
buffering automatically too.
- New functions in WINGs: WMGetColorAlpha(), WMIsAAFont()
- Misc code cleanups in WINGs and src/dialog.c
flickering.
- Added double buffering when drawing WMList items to avoid flickering
- Shared xft drawable
- Renamed AASystemFont and AABoldSystemFont to AntialiasedSystemFont
respectively AntialiasedBoldSystemFont in WMGLOBAL
- WMCreateFont falls back to normal fonts if antialiased fonts cannot be
created (even if enabled)
WMDrawString() and WMDrawImageString() now take WMColor instead of GC as
arguments. WMDrawImageString() receives 2 colors (text & background).
This is to allow easy extension for Xft/Xrender and hide X low level details
- Added alpha channel to WMColor. 2 new functions also:
WMCreateRGBAColor() and WMSetColorAlpha()
- Miscelaneous code cleanups in wtext.c
- Removed obsoleted acconfig.h and implemented its functionality using
AC_DEFINE and AC_DEFINE_UNQUOTED as autoconf 2.5x recommends.
This will definitely enforce the need to use autoconf 2.5x