Commit Graph

333 Commits

Author SHA1 Message Date
Kim Woelders 5ce609cca7 Change formatting style
No tabs, more like K&R.
Also switch to indent 2.2.13.
2023-11-26 10:03:45 +01:00
Kim Woelders b41a6a9a53 pagers: Avoid some overhead 2022-12-11 20:19:09 +01:00
Kim Woelders 546c1bb2df dialogs: Text cleanups
In general only capitalize first word.
Capitalization of words was somewhat inconsistent throughout the
dialogs.
2022-04-24 12:41:25 +02:00
Kim Woelders 3c42724f96 Dialog layout adjustments
In general left-align text labels.
2022-04-22 07:41:58 +02:00
Kim Woelders 8f82fe1559 pagers: Remember zoom setting when changed by pager menu 2021-11-13 18:50:17 +01:00
Kim Woelders 71d8448cea Fix pager update on desk switch
With composite enabled and doing pager snapshot/scan (not "live") the
screen must be repainted after desk switch before snapshotting.
2021-03-20 19:09:00 +01:00
Kim Woelders 358b60baf9 Introduce E_ARRAY_SIZE() and MOD_ITEMS()
Just a bit tidier.
2021-03-19 06:36:46 +01:00
Kim Woelders 7872361105 Remove unused Pager:name 2021-03-08 18:55:48 +01:00
Kim Woelders 84baa86492 Fix pager live updates if millisecond time is initially "negative" 2021-03-08 18:49:24 +01:00
Kim Woelders c839d0e14a src: Fix clang-analyzer complaints
arrange.c: Highly unlikely, maybe impossible situations

backgrounds.c: False positive (I think)

dialog.c: Fix memleak/segv on realloc failure

focus.c: False positive
	ewin should never be NULL with FOCUS_EWIN_NEW

main.c: False positive
	eoptarg will always be set if argument requires option

menus.c: Fix memleak on malloc failure

session.c: Fix dead assignment

stacking.c: False positive
	Changed code is nicer though

pager.c: False positive
	ewin would never be NULL if hiwin was NULL
	But rearrange for clarity anyway

ecompmgr.c: Avoid bogus issues
2020-01-29 16:43:01 +01:00
Kim Woelders 88dba1cfff Re-indent with indent-2.2.12 2020-01-23 21:30:02 +01:00
Kim Woelders 22b5e58dcd Refactor/rename/use _EFREE type macros 2018-12-22 11:44:22 +01:00
Kim Woelders ca5040e643 Remove pseudotransparency support - 3
- Remove obsolete image type argument.
2018-02-04 13:32:59 +01:00
Kim Woelders 45bf0da80d Slightly different fix to pager zoom/focus issue. 2015-03-23 19:32:48 +01:00
Kim Woelders 9c31fe29ed Clean up header file inclusion order.
Fixes building with e.g. -std=c99 and c11 by always including config.h
(which defines _GNU_SOURCE) first.
2015-01-17 19:33:42 +01:00
Kim Woelders 23872b2cac Simplify dialog data handling. 2014-04-29 19:42:15 +02:00
Kim Woelders 5fc86cc6ad Refactor dialog apply/exit handling.
Split into separate functions so we don't have to check on val all over
to figure out if it is one or the other.

This also avoids that the apply stuff may be done twice on exit a couple
of places.
2014-04-29 19:42:15 +02:00
Kim Woelders 2bf2bfd88e Use initially created GC for various operations.
A general "root window GC" is fine for most operations needing one.
Using this we can avoid some GC caching and in certain situations
numerous GC create/use/destroy sequences.

As part of this the default GC subwindow_mode is changed to
IncludeInferiors, which reduces the number of places we need a
non-default GC.
2014-04-23 19:45:36 +02:00
Kim Woelders 4d1bde02ae Wrap XID and some other X types.
Mostly to change longs to ints to reduce memory footprint a bit on 64
bit systems.
2014-04-23 19:13:00 +02:00
Kim Woelders c6e5a48817 Debug tweaks (pager). 2014-04-21 16:30:52 +02:00
Kim Woelders d1b7b142cf Wrap XDraw/FillRectangle. 2014-04-21 14:56:32 +02:00
Kim Woelders e48cfb2519 Simplify pager background update. 2014-04-21 14:56:32 +02:00
Kim Woelders 6ebf4fe167 Cosmetics. 2014-04-21 09:11:05 +02:00
Kim Woelders 248ec63e1e Wrap remaining XCopyArea calls. 2013-12-29 08:59:39 +01:00
Kim Woelders e1f062fff5 Use NoXID in stead of None. 2013-12-29 08:59:38 +01:00
Kim Woelders 94b5626c9a Trivial type fixes. 2013-12-29 08:59:38 +01:00
Kim Woelders e287b37e78 Switch to new list implementation.
Faster, less code, less memory usage.
Not that it matters much - mostly for fun.
2013-08-09 11:43:48 +02:00
Kim Woelders ccc5560d23 No need for double - change to float. 2013-07-07 23:35:16 +02:00
Kim Woelders 108a3a6042 Save some bytes in various structs. 2013-06-29 18:14:41 +02:00
Kim Woelders 307d86f555 Cosmetics - paving the way for other changes. 2013-06-14 19:47:07 +02:00
Kim Woelders acaf58fd94 Add EventsBlock().
Intended to enable running event loop without processing X events.

SVN revision: 78406
2012-10-24 17:20:32 +00:00
Kim Woelders 4e2029affc Don't prevent pager update due to ewin slide.
SVN revision: 73455
2012-07-07 14:05:59 +00:00
Kim Woelders 0786a813d0 EwinMove/Resize - Change various global/ewin flags to function parameter.
SVN revision: 70390
2012-04-22 17:39:37 +00:00
Kim Woelders c9c22f6fc6 Use WM_NAME in stead of WM_ICON_NAME in pager and iconbox.
SVN revision: 63209
2011-09-05 18:37:31 +00:00
Kim Woelders a87641f97e Warning fixes for gcc-4.6.
SVN revision: 56392
2011-01-30 00:07:50 +00:00
Kim Woelders a649a2e005 Use GetTimeMs/Us() in stead of GetTime().
SVN revision: 55892
2011-01-05 18:05:59 +00:00
Kim Woelders f0c0a4519c Change TimerAdd() and TimerSetInterval() time to ms.
SVN revision: 55891
2011-01-05 18:05:57 +00:00
Kim Woelders 61c4508ff3 Revert "If CM is active, change snap to live pager mode."
The live update mode is way too time consuming e.g. when playing movies.
Maybe throttle the pager update rate?
For now just re-enable using the old scanning mode when compositing is
active.
Noted by Zone Seventeen.

SVN revision: 54342
2010-11-08 19:33:31 +00:00
Kim Woelders 94bdab5de8 Fix rendering of argb windows in pager when compositing is enabled.
SVN revision: 53809
2010-10-23 10:22:56 +00:00
Kim Woelders d3895d6eec Move some code lines.
SVN revision: 53808
2010-10-23 10:22:54 +00:00
Kim Woelders 15ede64ea1 Introduce PmapMaskInit().
SVN revision: 53807
2010-10-23 10:22:52 +00:00
Kim Woelders 288a6c0541 FreePmapMask() -> PmapMaskFree().
SVN revision: 53806
2010-10-23 10:22:50 +00:00
Kim Woelders 47eeb79d54 In pager "live" mode (compositing enabled), reflect window transparency in pagers.
Noted by Ted Baltz.
Doesn't work properly for argb windows.

SVN revision: 51493
2010-08-21 14:40:01 +00:00
Kim Woelders 4ac03926da Adjustments for indent 2.2.11.
SVN revision: 50909
2010-08-08 19:03:34 +00:00
Kim Woelders 0466673fbf Trim whitespace from translatable strings.
SVN revision: 48723
2010-05-09 19:03:19 +00:00
Kim Woelders 31c97439d1 Fix potential segvs.
Could be triggered by early move/resizes, e.g. due to initially
shaded state.

SVN revision: 47727
2010-04-03 18:28:49 +00:00
Kim Woelders e2c3228dad Avoid QueryPointer in PagerHandleMotion.
SVN revision: 47705
2010-04-02 15:28:22 +00:00
Kim Woelders 4560a1db7c If CM is active, change snap to live pager mode.
SVN revision: 47697
2010-04-02 15:28:04 +00:00
Kim Woelders d5175a9574 Change some functions to macros, simplify setup stuff.
SVN revision: 46932
2010-03-07 07:05:18 +00:00
Kim Woelders 649076a27f Add check, no need for return value in EXFreeGC().
SVN revision: 45488
2010-01-23 14:26:31 +00:00