Commit graph

501 commits

Author SHA1 Message Date
Dana Jansens
18141d78da Merge branch 'backport' into work
Conflicts:

	openbox/client.c
2008-03-06 02:46:32 -05:00
Mikael Magnusson
232cbb9eb7 Don't leak auto-scaled RGBA textures. 2008-03-05 20:12:45 +01:00
Dana Jansens
ac255432b4 use g_debug for debug messages 2008-03-02 15:19:09 -05:00
Dana Jansens
da889f0365 set the right version in the new render and obt .pc files 2008-02-27 21:13:45 -05:00
Dana Jansens
deb5ef6243 obrender uses obt now, there is no obparser anymore 2008-02-27 21:09:19 -05:00
Dana Jansens
97de737767 Merge branch 'backport' into work
Conflicts:

	openbox/menuframe.c
	openbox/prompt.c
	openbox/prop.c
	openbox/prop.h
2008-02-22 12:31:26 -05:00
Dana Jansens
d9e6aa5643 Add theme options for menu line separators.
Added:
 menu.separator.color
 menu.separator.width
 menu.separator.padding.width
 menu.separator.padding.height
2008-02-22 12:13:02 -05:00
Dana Jansens
3263845459 Merge branch 'backport' into work
Conflicts:

	openbox/grab.c
	openbox/keyboard.c
2008-02-18 20:43:18 -05:00
Mikael Magnusson
71940dae6f Fix some typos in comments. 2008-02-17 19:14:59 +01:00
Dana Jansens
e1b4b9eb17 Merge branch 'backport' into work 2008-02-14 15:14:55 -05:00
Dana Jansens
3f62e77dea don't use \n at the end of g_message strings 2008-02-14 15:10:14 -05:00
Dana Jansens
66a897d9b2 don't reference free'd memory, and don't leak memory if the image cache is not saving any resized pictures 2008-02-14 15:10:14 -05:00
Dana Jansens
e7a86f5fe4 use g_message not g_print so it can go to the log 2008-02-14 15:10:14 -05:00
Dana Jansens
38c96413b3 pre-calc the sum of a picture added to an RrImage rather than calculating it every time 2008-02-14 15:10:14 -05:00
Dana Jansens
a2e3026d8a add a bunch of comments for images and image caches. and make the number of resized pictures saved in an image tunable per-icon cache. 2008-02-14 15:10:14 -05:00
Dana Jansens
35b36fc377 when resizing images, pick a source image with the same aspect ratio if possible 2008-02-14 15:10:14 -05:00
Dana Jansens
4c7cc1cfa6 Introducing the icon cache.
If an icon is the same as one in the cache, then it uses that one.
icons of different sizes (from the same client) are linked together into
one, and resizes of icons are cached and linked to all the various sizes.
so you only need one icon in memory for all your terminals now. ya!
2008-02-14 15:09:24 -05:00
Dana Jansens
512d93afcc backport the changes to render/ from the alttab branch (commit 3592046b2b) in master, as the iconcache changes depend on this
git show 3592046b -- render
2008-02-14 14:44:17 -05:00
Mikael Magnusson
e06ddf9f22 put the char member at the bottom of the struct so that it doesnt mess up alignment for the other members (assuming the compiler doesn't pad the struct appropriately anyways) 2008-02-14 14:35:28 -05:00
Dana Jansens
baf1a0919d fix min-size calculations for lineart textures 2008-02-14 14:24:37 -05:00
Dana Jansens
0da49e82ae when drawing and measuring strings in "flow" mode, don't ellipsize so that lines can wrap 2008-02-14 14:24:37 -05:00
Dana Jansens
7867ced622 allow font rendering to use multiple lines 2008-02-14 14:24:07 -05:00
Dana Jansens
c313b219a2 you can create dialog windows called "prompts" which have a message and some buttons! they don't do anything interesting yet. 2008-02-14 14:24:07 -05:00
Dana Jansens
957e07cbcc fix min-size calculations for lineart textures 2008-02-14 19:43:08 +01:00
Mikael Magnusson
c8ef10a0e1 put the char member at the bottom of the struct so that it doesnt mess up alignment for the other members (assuming the compiler doesn't pad the struct appropriately anyways) 2008-02-14 19:43:07 +01:00
Mikael Magnusson
1124d10369 Merge branch 'backport' into work
Diffing against the old work branch where most of the changes
in backport were cherry-picked from indicates this should be
alright. (0de9097017d4d1991388a35e380a57dc1135b431)
2008-02-14 19:43:02 +01:00
Dana Jansens
8f5540f76d turn the new openbox.png into the default icon.h 2008-02-14 19:40:03 +01:00
Dana Jansens
8186a81fe0 split menu overlap into x and y components 2008-02-14 19:40:02 +01:00
Dana Jansens
6bda8c2903 speed up the pyramid gradient using memcpy's. also make it not crash for 1px high textures.
here are some sample profiling results.  pyramid2 is the new code

  %   cumulative   self              self     total
 time   seconds   seconds    calls  ms/call  ms/call  name

 58.78      1.54     1.54      255     6.04     6.04  gradient_pyramid1
 40.46      2.60     1.06      255     4.16     4.16  gradient_pyramid2

 54.88      2.25     2.25      504     4.46     4.46  gradient_pyramid1
 44.88      4.09     1.84      504     3.65     3.65  gradient_pyramid2
2008-02-14 19:40:02 +01:00
Dana Jansens
b92cb6a08a remove an XXX comment, the sanity check seems to have worked out fine. 2008-02-14 19:40:02 +01:00
Dana Jansens
9c72998684 a small optimization for the vertical gradients, and use the same log(n) strategy to use less memcpy's for filling out the horizontal gradients 2008-02-14 19:40:02 +01:00
Dana Jansens
3611c8210c use memcpy's to speed up vertical gradients too. split the fancy memcpy() code out into the repeat_pixel function. 2008-02-14 19:40:02 +01:00
Dana Jansens
1d00d99470 use memcpy's to make splitvertical gradient much faster - using log n memcpy's is much quicker than setting a pointer value n times
Here are some profiling results.  splitvertical1 is the original code, splitvertical2 is some slight improvements in locality for it, and splitvertical3 is the new O(log n) memcpy code

  %   cumulative   self              self     total
 time   seconds   seconds    calls  ms/call  ms/call  name
 49.44      0.88     0.88     1063     0.83     0.83  gradient_splitvertical1
 47.19      1.72     0.84     1063     0.79     0.79  gradient_splitvertical2
  2.81      1.77     0.05     1063     0.05     0.05  gradient_splitvertical3

i also tested this with 'time' to draw 1000 gradients, and the new code used approximately half the user time, and finished 10 seconds quicker.  so yeah, it's magical and works well.
2008-02-14 19:40:02 +01:00
Dana Jansens
ed81992aea make rendertest exit cleanly when it is unmapped (iconify/desktopchange) 2008-02-14 19:40:01 +01:00
Dana Jansens
bbf0eed8d1 don't reference free'd memory, and don't leak memory if the image cache is not saving any resized pictures 2008-02-14 11:44:51 +01:00
Dana Jansens
87124ae865 use g_message not g_print so it can go to the log 2008-02-14 11:44:51 +01:00
Dana Jansens
1d62584742 pre-calc the sum of a picture added to an RrImage rather than calculating it every time 2008-02-14 11:44:51 +01:00
Dana Jansens
0cd9986f87 add a bunch of comments for images and image caches. and make the number of resized pictures saved in an image tunable per-icon cache. 2008-02-14 11:44:51 +01:00
Dana Jansens
5e204525de when resizing images, pick a source image with the same aspect ratio if possible 2008-02-14 11:44:50 +01:00
Dana Jansens
ea435b99a8 Introducing the icon cache.
If an icon is the same as one in the cache, then it uses that one.
icons of different sizes (from the same client) are linked together into
one, and resizes of icons are cached and linked to all the various sizes.
so you only need one icon in memory for all your terminals now. ya!
2008-02-14 11:44:28 +01:00
Dana Jansens
f0d31a52b7 make white font shadows (negative shadowtint) work right.. this has been busted a long time. thank you nvidia. 2008-02-10 01:52:08 -05:00
Mikael Magnusson
f6193ad9e0 Merge branch 'wip/alttab' 2008-02-07 15:28:18 +01:00
Dana Jansens
fcc23e1fd1 when drawing and measuring strings in "flow" mode, don't ellipsize so that lines can wrap 2008-02-07 02:14:45 -05:00
Dana Jansens
9e3ce4efed allow font rendering to use multiple lines 2008-02-07 02:14:44 -05:00
Dana Jansens
a01ece1353 you can create dialog windows called "prompts" which have a message and some buttons! they don't do anything interesting yet. 2008-02-07 02:14:43 -05:00
Dana Jansens
5f04ca85ef Merge branch 'backport' into work
Conflicts:

	openbox/config.c
2008-02-07 02:06:42 -05:00
Dana Jansens
bc13099405 show a small arrow on the top/bottom of the alttab list box when there are more windows that are not visible in that direction 2008-02-06 01:32:12 -05:00
Dana Jansens
87fd759ba9 the title_focused_shadow_color is being set twice, and being overridden by the osd color (though not in the texture) 2008-02-05 00:09:51 -05:00
Mikael Magnusson
3592046b2b Make the icon and hilite the proper sizes.
Had to add some obrender thingers and fiddle around a bit. Also fixed up
some confusing logic.
2008-02-03 00:28:02 -05:00
Dana Jansens
de0873824e split the version.h into render/ and obt/ copies, with the appropriate version info 2008-02-02 15:59:44 -05:00