From 088c0ac230447c683dec10bb4e6a40b4146fa479 Mon Sep 17 00:00:00 2001 From: dan Date: Tue, 9 Mar 1999 14:58:01 +0000 Subject: [PATCH] Update for 0.51.2-pre2 --- AUTHORS | 8 +- ChangeLog | 16 +- INSTALL | 12 +- Install | 6 +- NEWS | 11 + README | 12 +- TODO | 2 + WINGs/ChangeLog | 11 + WINGs/Resources/Images.tiff | Bin 15328 -> 15326 bytes WINGs/Resources/Images.xcf | Bin 43656 -> 43982 bytes WINGs/Resources/Images.xpm | 314 +++---- WINGs/WINGs.h | 19 +- WINGs/WINGsP.h | 8 +- WINGs/mywidget.c | 2 +- WINGs/testcolorpanel.c | 10 +- WINGs/userdefaults.c | 29 +- WINGs/wapplication.c | 1 - WINGs/wbrowser.c | 62 +- WINGs/wbutton.c | 8 +- WINGs/wcolor.c | 38 +- WINGs/wcolorpanel.c | 879 +++++++++--------- WINGs/wcolorwell.c | 69 +- WINGs/wfilepanel.c | 38 +- WINGs/wfont.c | 27 +- WINGs/wframe.c | 4 +- WINGs/widgets.c | 9 +- WINGs/wlabel.c | 4 +- WINGs/wlist.c | 4 +- WINGs/wmisc.c | 30 +- WINGs/wpixmap.c | 28 + WINGs/wpopupbutton.c | 17 +- WINGs/wscroller.c | 12 +- WINGs/wslider.c | 75 +- WINGs/wtextfield.c | 16 +- WINGs/wview.c | 35 +- WPrefs.app/Appearance.c | 230 ++++- WPrefs.app/Makefile.am | 1 - WPrefs.app/Makefile.in | 6 +- WPrefs.app/Menu.c | 1 + WPrefs.app/MouseSettings.c | 70 +- WPrefs.app/NoMenuAlert.c | 11 +- WPrefs.app/TextureAndColor.c | 686 --------------- WPrefs.app/TexturePanel.c | 978 +++++++++++---------- WPrefs.app/WPrefs.c | 58 +- WPrefs.app/WPrefs.h | 4 +- WPrefs.app/WindowHandling.c | 24 +- WPrefs.app/double.c | 4 +- WPrefs.app/editmenu.c | 8 +- WPrefs.app/main.c | 2 +- WPrefs.app/po/Makefile.am | 2 +- WPrefs.app/po/Makefile.in | 2 +- WindowMaker/Defaults/WindowMaker | 3 +- WindowMaker/Defaults/WindowMaker.in | 3 +- WindowMaker/Themes/Makefile.am | 2 +- WindowMaker/Themes/Makefile.in | 4 +- WindowMaker/Themes/Night.themed/Makefile.in | 2 +- WindowMaker/Themes/STEP2000.themed/BlueImage2.jpeg | Bin 0 -> 45024 bytes WindowMaker/Themes/STEP2000.themed/Makefile.am | 7 + .../{Night.themed => STEP2000.themed}/Makefile.in | 8 +- WindowMaker/Themes/STEP2000.themed/style | 48 + WindowMaker/menu.hu | Bin 7835 -> 7836 bytes WindowMaker/menu.zh_TW.Big5 | 12 +- acinclude.m4 | 115 ++- aclocal.m4 | 115 ++- configure | 519 +++++------ configure.in | 20 +- doc/Makefile.in | 2 +- po/Makefile.am | 2 +- po/Makefile.in | 4 +- src/Makefile.in | 2 +- src/WindowMaker.h | 9 + src/actions.c | 20 +- src/appicon.c | 21 +- src/client.c | 5 +- src/colormap.c | 4 +- src/config.h | 4 +- src/dialog.c | 8 +- src/dock.c | 25 +- src/event.c | 117 ++- src/icon.c | 5 +- src/kwm.c | 1 + src/moveres.c | 49 +- src/properties.c | 19 + src/properties.h | 1 + src/screen.c | 2 +- src/screen.h | 6 +- src/session.c | 5 - src/shutdown.c | 5 +- src/startup.c | 103 +-- src/wconfig.h | 2 +- src/wdefaults.c | 5 + src/window.c | 185 ++-- src/window.h | 5 + src/winspector.c | 38 +- src/winspector.h | 2 +- test/Makefile.in | 2 +- util/Makefile.am | 5 +- util/Makefile.in | 7 +- util/README | 2 +- util/setstyle.c | 12 +- util/wmaker.inst.in | 42 +- util/wmsetbg.c | 15 +- wmlib/Makefile.in | 2 +- wmlib/app.c | 4 +- wrlib/Makefile.am | 2 +- wrlib/Makefile.in | 4 +- wrlib/load.c | 45 +- wrlib/wraster.h | 9 +- 108 files changed, 2788 insertions(+), 2780 deletions(-) rewrite WINGs/Resources/Images.tiff (69%) delete mode 100644 WPrefs.app/TextureAndColor.c create mode 100755 WindowMaker/Themes/STEP2000.themed/BlueImage2.jpeg create mode 100755 WindowMaker/Themes/STEP2000.themed/Makefile.am copy WindowMaker/Themes/{Night.themed => STEP2000.themed}/Makefile.in (97%) create mode 100755 WindowMaker/Themes/STEP2000.themed/style rewrite WindowMaker/menu.hu (69%) diff --git a/AUTHORS b/AUTHORS index 112a3f7d..7de087dc 100644 --- a/AUTHORS +++ b/AUTHORS @@ -81,6 +81,9 @@ WINGs bug fixes, WINGs color panel Robert A. Holak bug fix +Michael Hokenson +wkde2menu.pl script + IKARASHI Akira Workspace change bug fix @@ -98,7 +101,7 @@ made autoarrange icons a runtime option, SHADOW_RESIZEBAR c-time option, no workspace switch to the same workspace, dashed icon selection, misclellaneous bug fixes -Alfredo K. Kojima +Alfredo K. Kojima Project maintainer Jay Kominek @@ -141,9 +144,6 @@ Dan Pascu dock ghost (superfluous mode) fix, enhancement for scrollable menus, clip, numerous other stuff, project maintainer -Kenneth W. Persinger Jr. -tcl/tk dockit - Biagio Pippa <1993s017@educ.disi.unige.it> fixed miniaturization with transient window diff --git a/ChangeLog b/ChangeLog index f03dc726..324b8919 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,15 @@ +Changes since version 0.51.1: +............................. + +- maximize for full screen +- fixed problem with frame drawing in non-opaque +- fixed installation path prob [jmknoble@pobox.com] +- fixed bug moving window when only one window is on screen +- fixed bug with ignored GNUstep attributes +- fixed WPrefs crash in Mouse Preferences +- fixed crash bug in WINGs/wmaker startup +- added workaround for kde pager crash bug + Changes since version 0.51.0: ............................. @@ -34,7 +46,9 @@ Changes since version 0.51.0: - fixed crash with internal dialogs and multi-heads - added standard colormap support to wrlib (taken from libXmu sources) - fixed memory leak in attribute panel -- fixed bug with window that can get focus if both shaded and hidden. +- fixed crash with CalendarManager deiconify +- fixed heisencrash when mapping new windows +- fixed totally buggy wmaker.inst ~/.xinitrc checker Changes since version 0.50.2: ............................. diff --git a/INSTALL b/INSTALL index 91bc05e0..d171af6f 100644 --- a/INSTALL +++ b/INSTALL @@ -19,7 +19,7 @@ SUPPORTED PLATFORMS - Solaris 2.6.0 - Solaris 2.7beta - SCO Unix -- SGI Irix +- SGI Irix 5.x, 6.5 - OSF/1 - HP-UX - AIX 4.1.4 / IBM PowerPC @@ -421,6 +421,10 @@ like not being able to use a graphic format library you think you have installed, look at the config.log file for clues of the problem. +== Error with loading fonts, even if they exist. + +Try rebuilding without NLS support. + == Error when configuring ltconfig: unrecognized option `--no-reexec' @@ -487,9 +491,9 @@ CPP_PATH. LOCALES/INTERNATIONALIZATION ============================ -Window Maker has national language support. -To enable national language support, you must compile -Window Maker with some additional parameters. +Window Maker has national language support. To enable national language +support, you must compile Window Maker with some additional parameters. + 0 - You must have the GNU gettext package installed. It can be obtained at ftp://prep.ai.mit.edu/pub/gnu/gettext-nnn.tar.gz diff --git a/Install b/Install index 9a42b1d3..d78e9daa 100755 --- a/Install +++ b/Install @@ -39,9 +39,9 @@ echo echo "NOTE: If this script fails, read the INSTALL file and" echo "install by hand." echo -echo "Please read the INSTALL and FAQ files before e-mailing " -echo "questions. (we are lazy to reply questions already answered " -echo "there as much as you are lazy to read these ;) " +echo "Please read the README, INSTALL and FAQ files before e-mailing " +echo "questions. We will IGNORE any questions that are already" +echo "answered in the documentation." echo perai echo diff --git a/NEWS b/NEWS index a8932ba6..f40eaad0 100644 --- a/NEWS +++ b/NEWS @@ -2,6 +2,17 @@ NEWS for veteran Window Maker users ----------------------------------- +--- 0.51.2 + +Full Screen Maximization +------------------------ + +The FullMaximize window attribute will allow the window to +be maximized to the full size of the screen (ignoring anything +like titlebar, resizebar, dock, panels etc). It should be usefull +for programs that must use the whole screen, like games or things +like presentation programs. + --- 0.51.1 diff --git a/README b/README index 3f5d1357..f7f74bf2 100644 --- a/README +++ b/README @@ -66,8 +66,10 @@ making windows and doors. Documentation ============= +Read before asking. + * README files all over the source tree have info related to the stuff -in the directories. +in the directories. * INSTALL has installation instructions and some troubleshooting tips. You're meant to read it before installing. it was not written just to @@ -302,17 +304,19 @@ to: #define NO_EMERGENCY_AUTORESTART Then, in the src directory type: +make clean make CFLAGS=-g make install and wait for Window Maker to be installed. Once having Window Maker installed, start X and reproduce the bug so -that Window Maker crashes. When it does crash, type the following from -your shell: +that Window Maker crashes. When it does crash, go to the directory +where you compiled wmaker and type the following from your shell: script -gdb wmaker path_to_the_core_file +cd src +gdb .libs/wmaker path_to_the_core_file Then, in the gdb prompt type "bt". Quit from gdb by typing "quit" and then, in the shell prompt, type "exit". diff --git a/TODO b/TODO index bde63d4c..3127b527 100644 --- a/TODO +++ b/TODO @@ -9,9 +9,11 @@ Do ASAP: - add multiline support for balloons - move/add balloon to WINGs - finish XStandardColormap stuff in wrlib +- finish menu editor/other stuff in wprefs Need to do: =========== +- put a "Do not save workspace state" in the exit confirmation dialog - allow user to select/restore default root menu from wprefs - fix windoze cycle window patch - support for X11R6.4 extension for getting extra visual info in wrlib's diff --git a/WINGs/ChangeLog b/WINGs/ChangeLog index 43c2bbbc..f9b04bd9 100644 --- a/WINGs/ChangeLog +++ b/WINGs/ChangeLog @@ -1,8 +1,19 @@ +changes since wmaker 0.51.1: +........................... + +- wusergnusteppath() will return a statically allocated string now. + DO NOT FREE IT ANYMORE!! + + + changes since wmaker 0.51.0: ............................ - applied c++ compat header patch from Martynas Kunigelis - added WMSetTextFieldBeveled() +- removed W_GC() : use WMColorGC() instead +- added WMCreatePixmap() +- changed WMSetTextFieldEnabled() to WMSetTextFieldEditable() changes since wmaker 0.50.1: ............................ diff --git a/WINGs/Resources/Images.tiff b/WINGs/Resources/Images.tiff dissimilarity index 69% index d1ff34e66b14ad74367ccaf4b6f7c2ce4a2356e5..2489b0e6c95a04bb480d2652f7cb4fccb1860c1f 100644 GIT binary patch delta 9753 zcwR-9XHb*d7w+HmLPA0hHKB(lMS2ZAAYf2bun~$7dO!q3k8cvv=s{2s^%#nZ1&tk# zEl5>SgQB7bHGl$tj|H$r#c-K>Kim(`%-U;z*lV7dHT(G~OJA3wqoVAAy}kg@$n>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zH`1i=bLlRoV%bLIjml3&m-X9eW_4yQLvMbh7Ji*6Uq@impt?`wPH;}&amJqxqa4!HhbQM4 zt}M=+D3Uzw?2q!a^JrLwmL4j@DID9?h=>fEQfApq#Z59y+l1&4wq3?nXrzIOkRh_h zqfc35(WiO!(thi;&Qp|@*PQ4&r6_m7`+JAfyWuN)cFXu&?_P}``m)s*`%rVLZ@0%O z#vE7Y!33``wh5&e5n-%+y>Irt??JFL5E1LMp0@j0*4dAsv5Old!XgAG!v^Oh2H=d! zyFR8WT9y8mT~u89YHE7s*SRZK|6DBb+wkQHzNDRgQ74^HV5jaD`I7Pr>VlK!lbobv z=wSvIymvhq@a&N~7eQgBYx20qV*kX}9_Qo}YN8g}4=s^tc%L_$)lyvpk#I}8Z*XV( z^@Fb*NIx_7=;%ZG?r3{!Q^q z~P)QOrW%P=8j2>n;+L2+AFx^%Yo47S`M@2Qdbqd)zxyyrjh^3H6`+gF<=ZtWbx z1K#f8T8?!=^7fO@CMmf}5TOb$m;44nRza%;iMX|*B}9xb7?0X6jA8%uQ~Xscf~!87==Y z&Gn^{BL@aCtK*t)UH--kLP<^yYyZ%Fnfj1neEHI(tYC#S4)XC*s)0+teJTOsWN#7N z$8jeP+=;VG+;(nU^g`LgCKwf?HhADY6#LkVg)cYI2dmJP(@=6tLs$I+BOk2&YOvxM c`5ef;z1BYRGw@sqc(V&QHkNA~{o&<*0f$~%-2eap diff --git a/WINGs/Resources/Images.xpm b/WINGs/Resources/Images.xpm index 9f4a1dfb..64855b69 100644 --- a/WINGs/Resources/Images.xpm +++ b/WINGs/Resources/Images.xpm @@ -25,65 +25,65 @@ static char * Images_xpm[] = { "/ c #424960", "( c #272A35", "_ c #0E1015", -": c #8295A0", -"< c #9E7576", -"[ c #323230", -"} c #56504B", -"| c #2C2119", -"1 c #8D9294", -"2 c #D3DAE0", -"3 c #C1C9D0", -"4 c #BFC2C4", -"5 c #070C1B", -"6 c #29354E", -"7 c #4E5A77", -"8 c #66718F", -"9 c #788094", -"0 c #828899", -"a c #848A9E", -"b c #7B8297", -"c c #676D84", -"d c #51576E", -"e c #3B4151", -"f c #1C1C20", -"g c #FFFFFF", -"h c #F8F8F8", -"i c #F1F1F1", -"j c #EAEAEA", -"k c #E4E4E4", -"l c #DDDDDD", -"m c #D6D6D6", -"n c #D0D0D0", -"o c #C9C9C9", -"p c #C2C2C2", -"q c #BBBBBB", -"r c #B5B5B5", -"s c #AEAEAE", -"t c #A7A7A7", -"u c #A1A1A1", -"v c #9A9A9A", -"w c #939393", -"x c #8C8C8C", -"y c #868686", -"z c #7F7F7F", -"A c #787878", -"B c #727272", -"C c #6B6B6B", -"D c #646464", -"E c #5D5D5D", -"F c #575757", -"G c #505050", -"H c #494949", -"I c #434343", -"J c #3C3C3C", -"K c #353535", -"L c #2E2E2E", -"M c #282828", -"N c #212121", -"O c #1A1A1A", -"P c #141414", -"Q c #0D0D0D", -"R c #060606", +": c #FFFFFF", +"< c #F8F8F8", +"[ c #F1F1F1", +"} c #EAEAEA", +"| c #E4E4E4", +"1 c #DDDDDD", +"2 c #D6D6D6", +"3 c #D0D0D0", +"4 c #C9C9C9", +"5 c #C2C2C2", +"6 c #BBBBBB", +"7 c #B5B5B5", +"8 c #AEAEAE", +"9 c #A7A7A7", +"0 c #A1A1A1", +"a c #9A9A9A", +"b c #939393", +"c c #8C8C8C", +"d c #868686", +"e c #7F7F7F", +"f c #787878", +"g c #727272", +"h c #6B6B6B", +"i c #646464", +"j c #5D5D5D", +"k c #575757", +"l c #505050", +"m c #494949", +"n c #434343", +"o c #3C3C3C", +"p c #353535", +"q c #2E2E2E", +"r c #282828", +"s c #212121", +"t c #1A1A1A", +"u c #141414", +"v c #0D0D0D", +"w c #060606", +"x c #8295A0", +"y c #9E7576", +"z c #323230", +"A c #56504B", +"B c #2C2119", +"C c #8D9294", +"D c #D3DAE0", +"E c #C1C9D0", +"F c #BFC2C4", +"G c #070C1B", +"H c #29354E", +"I c #4E5A77", +"J c #66718F", +"K c #788094", +"L c #828899", +"M c #848A9E", +"N c #7B8297", +"O c #676D84", +"P c #51576E", +"Q c #3B4151", +"R c #1C1C20", "S c #484848", "T c #20201E", "U c #634A48", @@ -336,49 +336,49 @@ static char * Images_xpm[] = { "r@ c #576789", "s@ c #546484", "t@ c #556788", -"u@ c #76787A", -"v@ c #413E38", -"w@ c #C6CBCD", -"x@ c #1F1B17", -"y@ c #A2A2A0", -"z@ c #E7ECF0", -"A@ c #F1F5F8", -"B@ c #BDC0C2", -"C@ c #373739", -"D@ c #47516B", -"E@ c #48546E", -"F@ c #485470", -"G@ c #495774", -"H@ c #4A5879", -"I@ c #4A5C7D", -"J@ c #0F131B", -"K@ c #7F8592", -"L@ c #CDD5E4", -"M@ c #D9E0F1", -"N@ c #CBD5EB", -"O@ c #A4AECE", -"P@ c #808BB3", -"Q@ c #707891", -"R@ c #6B7287", -"S@ c #6F778C", -"T@ c #C9D3E0", -"U@ c #C0CBDD", -"V@ c #A9BAD7", -"W@ c #A8B9D7", -"X@ c #90A4C7", -"Y@ c #141920", -"Z@ c #1B2531", -"`@ c #475F7E", -" # c #546C90", -".# c #6982A0", -"+# c #C0CFDC", -"@# c #8B9FB7", -"## c #56688A", -"$# c #515D7B", -"%# c #515B79", -"&# c #515B76", -"*# c #525D79", -"=# c #333333", +"u@ c #333333", +"v@ c #76787A", +"w@ c #413E38", +"x@ c #C6CBCD", +"y@ c #1F1B17", +"z@ c #A2A2A0", +"A@ c #E7ECF0", +"B@ c #F1F5F8", +"C@ c #BDC0C2", +"D@ c #373739", +"E@ c #47516B", +"F@ c #48546E", +"G@ c #485470", +"H@ c #495774", +"I@ c #4A5879", +"J@ c #4A5C7D", +"K@ c #0F131B", +"L@ c #7F8592", +"M@ c #CDD5E4", +"N@ c #D9E0F1", +"O@ c #CBD5EB", +"P@ c #A4AECE", +"Q@ c #808BB3", +"R@ c #707891", +"S@ c #6B7287", +"T@ c #6F778C", +"U@ c #C9D3E0", +"V@ c #C0CBDD", +"W@ c #A9BAD7", +"X@ c #A8B9D7", +"Y@ c #90A4C7", +"Z@ c #141920", +"`@ c #1B2531", +" # c #475F7E", +".# c #546C90", +"+# c #6982A0", +"@# c #C0CFDC", +"## c #8B9FB7", +"$# c #56688A", +"%# c #515D7B", +"&# c #515B79", +"*# c #515B76", +"=# c #525D79", "-# c #9A9B9B", ";# c #BEC2C5", "># c #959A9E", @@ -2088,24 +2088,24 @@ static char * Images_xpm[] = { " ", " ", " . + @ # $ % $ & ", -" * = - ; > , ' ) ! ~ { ] ^ / ( _ ", -" : < [ } | 1 2 3 3 > 4 5 6 7 8 9 0 a b c d e f @ g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R ", -" S T U V W X Y 2 3 Z > Z Z ` ...+.@.#.$.%.&.*.^ =.-.;.>. g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R ", -" ,.'.).!.~.{.].^./.2 > > > > > 2 (. _.:.<._.[.}.|.1.2.3.4.5.6.7.8.9.0.a.b.c.d.e.f.g.h.i.j.k.l.m.n.o.p.q.r. g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R ", -" s.+ t.u.v.w.x.y.z.A.B.C.D.E.F.G.2 ; H. I.J.K.L.<.M.N.O.P.Q.R.S.T.U.V.W.X.Y.Z.`. +.+++@+#+$+m.m.%+&+*+=+-+;+r. g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R ", -" >+,+'+C.)+4 4 !+; /.~+{+]+^+/+(+_+:+<+[+ }+|+|+1+2+3+4+5+6+7+8+9+0+a+b+c+d+e+f+g+h+i+j+k+l+m+n+o+p+q+r+s+t+u+v+ g h i j k l m n o p q r s t u v w x y z A B C D E F G H I J K L M N O P Q R ", -" w+x+; y+3 z+A+B+> 3 C+D+E+/.F+G+^.3 H+I+ J+K+L+M+N+L.O+P+Q+R+S+T+U+V+W+X+Y+Z+`+ @.@+@@@#@$@%@&@*@=@-@;@>@,@'@)@ ", -" !@~@C+{@^+]@^@B+2 2 ^./@(@/._@:@^.Z <@L [@}@|@1@2@N+3@4@5@6@7@8@9@0@a@b@c@d@e@f@g@h@i@j@k@l@=+m@n@o@p@q@r@s@t@ g g g g g g g g g g g g g g g g g g g g g g g g g g g g g g ", -" u@v@w@x@^.A+y@B+z@z@+ z ~+A@/@z.z@/.B@C@ 1@D@E@F@G@H@I@J@K@L@M@N@O@P@Q@R@S@T@U@V@W@X@W.Y@Z@`@ #.#+#@###$#%#&#*# g z z z z =# g z z z z =# g z z z z =# g z z z z =# g z z z z =# ", -" u@-#^.;#; > z@>#,#'#D+)#y+!#,#~#{#'#]#^# 1@/#(#_#_#H@:#<#[#}#|#1#2#3#4#5#6#7#8#9#9#0#a#b#c#d#e#f#g#h#i#=.j#k#l# g z z z z =# g z z z z =# g z z z z =# g z z z z =# g z z z z =# ", -" !@/././.2 2 /.m#w@n#-#z+z o#p#q#r#s#n#t#u# v#w#x#y#z#A#B#C#D#E#F#G#H#I#J#K#L#M#N#O#O#P#Q#R#S#T#U#V#W#X#Y#Z#`# $l# g z z z z =# g z z z z =# g z z z z =# g z z z z =# g z z z z =# ", -".$+$@$n##$2 $$;#%$&$x@z D+*$F+&$=$-$;$>$z ,$'$ )$!$~${$]$^$/$($_$:$<$[$}$|$1$2$3$4$5$6$7$8$9$0$a$b$c$d$e$f$g$h$i$j$k$ g =#=#=#=#=# g =#=#=#=#=# g =#=#=#=#=# g =#=#=#=#=# g =#=#=#=#=# ", -" z@l$(@m$/.D.C+n$o$'#$$'#p$q$r$/@s$t$u$t$/@'$ v$w$x$y$z$A$B$C$D$E$F$G$H$I$J$K$L$M$N$7$O$P$Q$R$S$T$U$V$W$X$Y$Z$`$ %.% ", -" A@q$+%@%/.;$C+#%$%%%$$'#t$&%*%=%-%;%>%s$u#I+ ,%'%)%!%~%{%]%^%/%(%_%:%<%[%}%|%1%2%3%4%5%6%7%8%9%0%a%X$b%c%d%e%f%g%h% g g g g g g g g g g g g g g g g g g g g g g g g g g g g g g ", -" z@E.4 i%2 j%k%#%l%m%n%o%p%q%r%s%t%u%v%w%u%x% y%z%A%)%!%B%C%D%E%F%G%H%I%J%K%L%M%N%O%P%Q%R%S%T%U%V%W%X%Y%Z%`% &.&+&@& g z z z z =# g z z z z =# g z z z z =# g z z z z =# g z z z z =# ", -" z $$n##&, $&%&&&)+(@*&z z /+u$=&B+>%-&s%;&I+ >&,&z%'&)&!&~&{&]&^&/&(&_&:&<&[&}&|&1&2&3&4&5&6&7&8&9&`$0&a&b&c&d&e&f& g z z z z =# g z z z z =# g z z z z =# g z z z z =# g z z z z =# ", -" g&h&i&{@j&k&r$r$*%r$t$l&,#m&p$t.@%F+n&#$o&'$ p&q&r&s&'&t&u&v&w&x&y&z&A&B&C&D&E&F&G&H&I&J&K&L&M&N&O&P&Q&R&S&T&U&V&W& g z z z z =# g z z z z =# g z z z z =# g z z z z =# g z z z z =# ", -" I+'$X&Y&Z&`& *.*t$+*t$.*q$q$q$/@q$q$@*'$ #*$*%*&***P&=*O&-*;*>*,*'*)*!*~*{*]*^*/*(*_*:*<*[*}*|*1*2*3*4*5*6*7*8* g =#=#=#=#=# g =#=#=#=#=# g =#=#=#=#=# g =#=#=#=#=# g =#=#=#=#=# ", +" * = - ; > , ' ) ! ~ { ] ^ / ( _ : < [ } | 1 2 3 4 5 6 7 8 9 0 a b c d e f g h i j k l m n o p q r s t u v w ", +" x y z A B C D E E > F G H I J K L M N O P Q R @ : < [ } | 1 2 3 4 5 6 7 8 9 0 a b c d e f g h i j k l m n o p q r s t u v w ", +" S T U V W X Y D E Z > Z Z ` ...+.@.#.$.%.&.*.^ =.-.;.>. : < [ } | 1 2 3 4 5 6 7 8 9 0 a b c d e f g h i j k l m n o p q r s t u v w ", +" ,.'.).!.~.{.].^./.D > > > > > D (. _.:.<._.[.}.|.1.2.3.4.5.6.7.8.9.0.a.b.c.d.e.f.g.h.i.j.k.l.m.n.o.p.q.r. : < [ } | 1 2 3 4 5 6 7 8 9 0 a b c d e f g h i j k l m n o p q r s t u v w ", +" s.+ t.u.v.w.x.y.z.A.B.C.D.E.F.G.D ; H. I.J.K.L.<.M.N.O.P.Q.R.S.T.U.V.W.X.Y.Z.`. +.+++@+#+$+m.m.%+&+*+=+-+;+r. : < [ } | 1 2 3 4 5 6 7 8 9 0 a b c d e f g h i j k l m n o p q r s t u v w ", +" >+,+'+C.)+F F !+; /.~+{+]+^+/+(+_+:+<+[+ }+|+|+1+2+3+4+5+6+7+8+9+0+a+b+c+d+e+f+g+h+i+j+k+l+m+n+o+p+q+r+s+t+u+v+ ", +" w+x+; y+E z+A+B+> E C+D+E+/.F+G+^.E H+I+ J+K+L+M+N+L.O+P+Q+R+S+T+U+V+W+X+Y+Z+`+ @.@+@@@#@$@%@&@*@=@-@;@>@,@'@)@ : : : : : : : : : : : : : : : : : : : : : : : : : : : : : : ", +" !@~@C+{@^+]@^@B+D D ^./@(@/._@:@^.Z <@q [@}@|@1@2@N+3@4@5@6@7@8@9@0@a@b@c@d@e@f@g@h@i@j@k@l@=+m@n@o@p@q@r@s@t@ : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ ", +" v@w@x@y@^.A+z@B+A@A@+ e ~+B@/@z.A@/.C@D@ 1@E@F@G@H@I@J@K@L@M@N@O@P@Q@R@S@T@U@V@W@X@Y@W.Z@`@ #.#+#@###$#%#&#*#=# : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ ", +" v@-#^.;#; > A@>#,#'#D+)#y+!#,#~#{#'#]#^# 1@/#(#_#_#I@:#<#[#}#|#1#2#3#4#5#6#7#8#9#9#0#a#b#c#d#e#f#g#h#i#=.j#k#l# : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ ", +" !@/././.D D /.m#x@n#-#z+e o#p#q#r#s#n#t#u# v#w#x#y#z#A#B#C#D#E#F#G#H#I#J#K#L#M#N#O#O#P#Q#R#S#T#U#V#W#X#Y#Z#`# $l# : u@u@u@u@u@ : u@u@u@u@u@ : u@u@u@u@u@ : u@u@u@u@u@ : u@u@u@u@u@ ", +".$+$@$n##$D $$;#%$&$y@e D+*$F+&$=$-$;$>$e ,$'$ )$!$~${$]$^$/$($_$:$<$[$}$|$1$2$3$4$5$6$7$8$9$0$a$b$c$d$e$f$g$h$i$j$k$ ", +" A@l$(@m$/.D.C+n$o$'#$$'#p$q$r$/@s$t$u$t$/@'$ v$w$x$y$z$A$B$C$D$E$F$G$H$I$J$K$L$M$N$7$O$P$Q$R$S$T$U$V$W$X$Y$Z$`$ %.% : : : : : : : : : : : : : : : : : : : : : : : : : : : : : : ", +" B@q$+%@%/.;$C+#%$%%%$$'#t$&%*%=%-%;%>%s$u#I+ ,%'%)%!%~%{%]%^%/%(%_%:%<%[%}%|%1%2%3%4%5%6%7%8%9%0%a%X$b%c%d%e%f%g%h% : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ ", +" A@E.F i%D j%k%#%l%m%n%o%p%q%r%s%t%u%v%w%u%x% y%z%A%)%!%B%C%D%E%F%G%H%I%J%K%L%M%N%O%P%Q%R%S%T%U%V%W%X%Y%Z%`% &.&+&@& : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ ", +" e $$n##&, $&%&&&)+(@*&e e /+u$=&B+>%-&s%;&I+ >&,&z%'&)&!&~&{&]&^&/&(&_&:&<&[&}&|&1&2&3&4&5&6&7&8&9&`$0&a&b&c&d&e&f& : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ : e e e e u@ ", +" g&h&i&{@j&k&r$r$*%r$t$l&,#m&p$t.@%F+n&#$o&'$ p&q&r&s&'&t&u&v&w&x&y&z&A&B&C&D&E&F&G&H&I&J&K&L&M&N&O&P&Q&R&S&T&U&V&W& : u@u@u@u@u@ : u@u@u@u@u@ : u@u@u@u@u@ : u@u@u@u@u@ : u@u@u@u@u@ ", +" I+'$X&Y&Z&`& *.*t$+*t$.*q$q$q$/@q$q$@*'$ #*$*%*&***P&=*O&-*;*>*,*'*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; ,;,;,; ,; ,;,;,; |(1(2(3(4(5(6(7(8(9(0(a(b(c(d(e(f(g(h(i(j(k(l(m(n(o(p(q(r(s(t(u( ", " ", " ", diff --git a/WINGs/WINGs.h b/WINGs/WINGs.h index 55c5c322..61140c6a 100644 --- a/WINGs/WINGs.h +++ b/WINGs/WINGs.h @@ -6,7 +6,7 @@ #include #include -#define WINGS_H_VERSION 981220 +#define WINGS_H_VERSION 990222 #ifdef __cplusplus @@ -512,6 +512,9 @@ WMPixmap *WMRetainPixmap(WMPixmap *pixmap); void WMReleasePixmap(WMPixmap *pixmap); +WMPixmap *WMCreatePixmap(WMScreen *scrPtr, int width, int height, int depth, + Bool masked); + WMPixmap *WMCreatePixmapFromXPixmaps(WMScreen *scrPtr, Pixmap pixmap, Pixmap mask, int width, int height, int depth); @@ -774,9 +777,9 @@ void WMSetTextFieldBordered(WMTextField *tPtr, Bool bordered); void WMSetTextFieldBeveled(WMTextField *tPtr, Bool flag); -Bool WMGetTextFieldEnabled(WMTextField *tPtr); +Bool WMGetTextFieldEditable(WMTextField *tPtr); -void WMSetTextFieldEnabled(WMTextField *tPtr, Bool flag); +void WMSetTextFieldEditable(WMTextField *tPtr, Bool flag); void WMSetTextFieldSecure(WMTextField *tPtr, Bool flag); @@ -944,13 +947,19 @@ WMColorPanel *WMGetColorPanel(WMScreen *scrPtr); void WMFreeColorPanel(WMColorPanel *panel); -int WMRunColorPanel(WMColorPanel *panel, WMWindow *owner, RColor color); +void WMShowColorPanel(WMColorPanel *panel); + +void WMCloseColorPanel(WMColorPanel *panel); void WMSetColorPanelColor(WMColorPanel *panel, RColor color); RColor WMGetColorPanelColor(WMColorPanel *panel); -void WMSetPickerMode(WMColorPanel *panel, WMColorPanelMode mode); +void WMSetColorPanelPickerMode(WMColorPanel *panel, WMColorPanelMode mode); + +void WMSetColorPanelAction(WMColorPanel *panel, WMAction *action, void *data); + + /* ....................................................................... */ diff --git a/WINGs/WINGsP.h b/WINGs/WINGsP.h index 0ce3a432..fdd0c602 100644 --- a/WINGs/WINGsP.h +++ b/WINGs/WINGsP.h @@ -9,7 +9,7 @@ #include "WINGs.h" #include "WUtil.h" -#if WINGS_H_VERSION < 981220 +#if WINGS_H_VERSION < 990222 #error There_is_an_old_WINGs.h_file_somewhere_in_your_system._Please_remove_it. #endif @@ -59,6 +59,7 @@ typedef struct W_Font { short height; short y; short refCount; + char *name; unsigned int notFontSet:1; } W_Font; @@ -156,7 +157,9 @@ typedef struct W_Screen { W_Font *normalFont; W_Font *boldFont; - + + WMHashTable *fontCache; + struct W_Pixmap *checkButtonImageOn; struct W_Pixmap *checkButtonImageOff; @@ -324,7 +327,6 @@ _WINGsConfiguration WINGsConfiguration; #define W_VIEW_MAPPED(view) (view)->flags.mapped #define W_PIXEL(c) (c)->color.pixel -#define W_GC(c) (c)->gc #define W_FONTID(f) (f)->font->fid diff --git a/WINGs/mywidget.c b/WINGs/mywidget.c index d551b2a7..9ea732f7 100644 --- a/WINGs/mywidget.c +++ b/WINGs/mywidget.c @@ -146,7 +146,7 @@ paintMyWidget(_MyWidget *mPtr) color = WMWhiteColor(scr); W_PaintText(mPtr->view, mPtr->view->window, scr->normalFont, 0, 0, - mPtr->view->size.width, WACenter, W_GC(color), + mPtr->view->size.width, WACenter, WMColorGC(color), False, mPtr->text, strlen(mPtr->text)); WMReleaseColor(color); diff --git a/WINGs/testcolorpanel.c b/WINGs/testcolorpanel.c index b1efabdf..2cc597f7 100644 --- a/WINGs/testcolorpanel.c +++ b/WINGs/testcolorpanel.c @@ -25,7 +25,7 @@ int main(int argc, char **argv) WMScreen *scr; WMPixmap *pixmap; WMColorPanel *panel; - RColor startcolor; + WMInitializeApplication("WMColorPicker", &argc, argv); @@ -44,10 +44,8 @@ int main(int argc, char **argv) WMSetApplicationIconImage(scr, pixmap); WMReleasePixmap(pixmap); panel = WMGetColorPanel(scr); - startcolor.red = 0; - startcolor.green = 0; - startcolor.blue = 255; - - WMRunColorPanel(panel, NULL, startcolor); + WMShowColorPanel(panel); + + WMScreenMainLoop(scr); return 0; } diff --git a/WINGs/userdefaults.c b/WINGs/userdefaults.c index c97dbd62..d8b06829 100644 --- a/WINGs/userdefaults.c +++ b/WINGs/userdefaults.c @@ -35,22 +35,24 @@ extern char *WMGetApplicationName(); char* wusergnusteppath() { - char *path; + static char *path = NULL; char *gspath; int pathlen; - gspath = getenv("GNUSTEP_USER_ROOT"); - if (gspath) { - gspath = wexpandpath(gspath); - pathlen = strlen(gspath) + 4; - path = wmalloc(pathlen); - strcpy(path, gspath); - free(gspath); - } else { - pathlen = strlen(wgethomedir()) + 10; - path = wmalloc(pathlen); - strcpy(path, wgethomedir()); - strcat(path, "/GNUstep"); + if (!path) { + gspath = getenv("GNUSTEP_USER_ROOT"); + if (gspath) { + gspath = wexpandpath(gspath); + pathlen = strlen(gspath) + 4; + path = wmalloc(pathlen); + strcpy(path, gspath); + free(gspath); + } else { + pathlen = strlen(wgethomedir()) + 10; + path = wmalloc(pathlen); + strcpy(path, wgethomedir()); + strcat(path, "/GNUstep"); + } } return path; @@ -66,7 +68,6 @@ wdefaultspathfordomain(char *domain) gspath = wusergnusteppath(); path = wmalloc(strlen(gspath)+strlen(DEFAULTS_DIR)+strlen(domain)+4); strcpy(path, gspath); - free(gspath); strcat(path, DEFAULTS_DIR); strcat(path, "/"); strcat(path, domain); diff --git a/WINGs/wapplication.c b/WINGs/wapplication.c index b55d9d5e..5b979492 100644 --- a/WINGs/wapplication.c +++ b/WINGs/wapplication.c @@ -173,7 +173,6 @@ WMPathForResourceOfType(char *resource, char *ext) tmp = wusergnusteppath(); if (tmp) { path = checkFile(tmp, appdir, ext, resource); - free(tmp); if (path) { free(appdir); return path; diff --git a/WINGs/wbrowser.c b/WINGs/wbrowser.c index 6d8687f8..dcd73b06 100644 --- a/WINGs/wbrowser.c +++ b/WINGs/wbrowser.c @@ -229,7 +229,7 @@ drawTitleOfColumn(WMBrowser *bPtr, int column) x=(column-bPtr->firstVisibleColumn)*(bPtr->columnSize.width+COLUMN_SPACING); - XFillRectangle(scr->display, bPtr->view->window, W_GC(scr->darkGray), x, 0, + XFillRectangle(scr->display, bPtr->view->window, WMColorGC(scr->darkGray), x, 0, bPtr->columnSize.width, bPtr->titleHeight); W_DrawRelief(scr, bPtr->view->window, x, 0, bPtr->columnSize.width, bPtr->titleHeight, WRSunken); @@ -245,13 +245,13 @@ drawTitleOfColumn(WMBrowser *bPtr, int column) &titleLen, widthC); W_PaintText(bPtr->view, bPtr->view->window, scr->boldFont, x, (bPtr->titleHeight-WMFontHeight(scr->boldFont))/2, - bPtr->columnSize.width, WACenter, W_GC(scr->white), + bPtr->columnSize.width, WACenter, WMColorGC(scr->white), False, titleBuf, titleLen); free (titleBuf); } else { W_PaintText(bPtr->view, bPtr->view->window, scr->boldFont, x, (bPtr->titleHeight-WMFontHeight(scr->boldFont))/2, - bPtr->columnSize.width, WACenter, W_GC(scr->white), + bPtr->columnSize.width, WACenter, WMColorGC(scr->white), False, bPtr->titles[column], titleLen); } } @@ -267,7 +267,7 @@ WMSetBrowserColumnTitle(WMBrowser *bPtr, int column, char *title) if (bPtr->titles[column]) free(bPtr->titles[column]); - bPtr->titles[column] = (title!=NULL) ? wstrdup(title) : wstrdup(""); + bPtr->titles[column] = wstrdup(title); if (COLUMN_IS_VISIBLE(bPtr, column) && bPtr->flags.isTitled) { drawTitleOfColumn(bPtr, column); @@ -517,7 +517,7 @@ paintItem(WMList *lPtr, int index, Drawable d, char *text, int state, y = rect->pos.y; if (state & WLDSSelected) - XFillRectangle(scr->display, d, W_GC(scr->white), x, y, + XFillRectangle(scr->display, d, WMColorGC(scr->white), x, y, width, height); else XClearArea(scr->display, d, x, y, width, height, False); @@ -530,24 +530,24 @@ paintItem(WMList *lPtr, int index, Drawable d, char *text, int state, char *textBuf = createTruncatedString(scr->normalFont, text, &textLen, widthC); W_PaintText(view, d, scr->normalFont, x+4, y, widthC, - WALeft, W_GC(scr->black), False, textBuf, textLen); + WALeft, WMColorGC(scr->black), False, textBuf, textLen); free(textBuf); } else { W_PaintText(view, d, scr->normalFont, x+4, y, widthC, - WALeft, W_GC(scr->black), False, text, textLen); + WALeft, WMColorGC(scr->black), False, text, textLen); } } if (state & WLDSIsBranch) { - XDrawLine(scr->display, d, W_GC(scr->darkGray), x+width-11, y+3, + XDrawLine(scr->display, d, WMColorGC(scr->darkGray), x+width-11, y+3, x+width-6, y+height/2); if (state & WLDSSelected) - XDrawLine(scr->display, d,W_GC(scr->gray), x+width-11, y+height-5, + XDrawLine(scr->display, d,WMColorGC(scr->gray), x+width-11, y+height-5, x+width-6, y+height/2); else - XDrawLine(scr->display, d,W_GC(scr->white), x+width-11, y+height-5, + XDrawLine(scr->display, d,WMColorGC(scr->white), x+width-11, y+height-5, x+width-6, y+height/2); - XDrawLine(scr->display, d, W_GC(scr->black), x+width-12, y+3, + XDrawLine(scr->display, d, WMColorGC(scr->black), x+width-12, y+3, x+width-12, y+height-5); } } @@ -893,31 +893,27 @@ listCallback(void *self, void *clientData) int i; item = WMGetListSelectedItem(lPtr); - if (!item) { - oldItem = item; - return; + if (!item || oldItem == item) + return; + + for (i=0; icolumnCount; i++) { + if (lPtr == bPtr->columns[i]) + break; } + assert(icolumnCount); - if (oldItem != item) { - for (i=0; icolumnCount; i++) { - if (lPtr == bPtr->columns[i]) - break; - } - assert(icolumnCount); - - /* columns at right must be cleared */ - removeColumn(bPtr, i+1); - /* open directory */ - if (item->isBranch) { - WMAddBrowserColumn(bPtr); - loadColumn(bPtr, bPtr->usedColumnCount-1); - } - if (bPtr->usedColumnCount < bPtr->maxVisibleColumns) - i = 0; - else - i = bPtr->usedColumnCount-bPtr->maxVisibleColumns; - scrollToColumn(bPtr, i, True); + /* columns at right must be cleared */ + removeColumn(bPtr, i+1); + /* open directory */ + if (item->isBranch) { + WMAddBrowserColumn(bPtr); + loadColumn(bPtr, bPtr->usedColumnCount-1); } + if (bPtr->usedColumnCount < bPtr->maxVisibleColumns) + i = 0; + else + i = bPtr->usedColumnCount-bPtr->maxVisibleColumns; + scrollToColumn(bPtr, i, True); /* call callback for click */ if (bPtr->action) diff --git a/WINGs/wbutton.c b/WINGs/wbutton.c index 31ee5ede..70600ec6 100644 --- a/WINGs/wbutton.c +++ b/WINGs/wbutton.c @@ -511,7 +511,7 @@ paintButton(Button *bPtr) if (bPtr->flags.selected) { if (bPtr->flags.stateLight) - gc = W_GC(scrPtr->white); + gc = WMColorGC(scrPtr->white); if (bPtr->flags.stateChange) { if (bPtr->altCaption) { @@ -533,7 +533,7 @@ paintButton(Button *bPtr) offset = 1; } if (bPtr->flags.pushLight) - gc = W_GC(scrPtr->white); + gc = WMColorGC(scrPtr->white); if (bPtr->flags.pushChange) { if (bPtr->altCaption) { @@ -546,9 +546,9 @@ paintButton(Button *bPtr) if (bPtr->flags.enabled) - textGC = W_GC(scrPtr->black); + textGC = WMColorGC(scrPtr->black); else - textGC = W_GC(scrPtr->darkGray); + textGC = WMColorGC(scrPtr->darkGray); W_PaintTextAndImage(bPtr->view, True, textGC, (bPtr->font!=NULL ? bPtr->font : scrPtr->normalFont), diff --git a/WINGs/wcolor.c b/WINGs/wcolor.c index a00d1eb8..6ae38abd 100644 --- a/WINGs/wcolor.c +++ b/WINGs/wcolor.c @@ -31,7 +31,6 @@ findCloseColor(WMScreen *scr, unsigned short red, unsigned short green, WMColor *color; XColor xcolor; RColor rcolor; - XGCValues gcv; rcolor.red = red>>8; rcolor.green = green>>8; @@ -49,11 +48,7 @@ findCloseColor(WMScreen *scr, unsigned short red, unsigned short green, color->refCount = 1; color->color = xcolor; color->flags.exact = 1; - - gcv.foreground = color->color.pixel; - gcv.graphics_exposures = False; - color->gc = XCreateGC(scr->display, scr->rcontext->drawable, - GCForeground|GCGraphicsExposures, &gcv); + color->gc = NULL; return color; } @@ -65,7 +60,6 @@ createRGBColor(WMScreen *scr, unsigned short red, unsigned short green, unsigned short blue) { WMColor *color; - XGCValues gcv; XColor xcolor; xcolor.red = red; @@ -81,11 +75,7 @@ createRGBColor(WMScreen *scr, unsigned short red, unsigned short green, color->refCount = 1; color->color = xcolor; color->flags.exact = 1; - - gcv.foreground = color->color.pixel; - gcv.graphics_exposures = False; - color->gc = XCreateGC(scr->display, scr->rcontext->drawable, - GCForeground|GCGraphicsExposures, &gcv); + color->gc = NULL; return color; } @@ -116,8 +106,10 @@ WMCreateNamedColor(WMScreen *scr, char *name, Bool exact) if (!XParseColor(scr->display, scr->colormap, name, &xcolor)) return NULL; - - + + if (scr->visual->class == TrueColor) + exact = True; + if (!exact || !(color=createRGBColor(scr, xcolor.red, xcolor.green, xcolor.blue))) { color = findCloseColor(scr, xcolor.red, xcolor.green, xcolor.blue); @@ -146,7 +138,8 @@ WMReleaseColor(WMColor *color) if (color->refCount < 1) { XFreeColors(color->screen->display, color->screen->colormap, &(color->color.pixel), 1, 0); - XFreeGC(color->screen->display, color->gc); + if (color->gc) + XFreeGC(color->screen->display, color->gc); free(color); } } @@ -156,7 +149,8 @@ void WMPaintColorSwatch(WMColor *color, Drawable d, int x, int y, unsigned int width, unsigned int height) { - XFillRectangle(color->screen->display, d, color->gc, x, y, width, height); + XFillRectangle(color->screen->display, d, WMColorGC(color), + x, y, width, height); } @@ -170,6 +164,16 @@ WMColorPixel(WMColor *color) GC WMColorGC(WMColor *color) { + if (!color->gc) { + XGCValues gcv; + WMScreen *scr = color->screen; + + gcv.foreground = color->color.pixel; + gcv.graphics_exposures = False; + color->gc = XCreateGC(scr->display, scr->rcontext->drawable, + GCForeground|GCGraphicsExposures, &gcv); + } + return color->gc; } @@ -226,7 +230,6 @@ WMGrayColor(WMScreen *scr) LIGHT_STIPPLE_HEIGHT); color = createRGBColor(scr, 0xffff, 0xffff, 0xffff); - XFreeGC(scr->display, color->gc); gcv.foreground = white->color.pixel; gcv.background = black->color.pixel; @@ -268,7 +271,6 @@ WMDarkGrayColor(WMScreen *scr) DARK_STIPPLE_HEIGHT); color = createRGBColor(scr, 0, 0, 0); - XFreeGC(scr->display, color->gc); gcv.foreground = white->color.pixel; gcv.background = black->color.pixel; diff --git a/WINGs/wcolorpanel.c b/WINGs/wcolorpanel.c index dd46186a..27ca13e6 100644 --- a/WINGs/wcolorpanel.c +++ b/WINGs/wcolorpanel.c @@ -2,21 +2,20 @@ * ColorPanel for WINGs * * by ]d : Original idea and basic initial code - * Pascal Hofstee : Code for wheeldrawing and calculating colors from it - * Alban Hertroys : Suggesting optimizations for algorithms for color- - * wheel, and implementation of final algorithm. - * Alfredo K. Kojima : For pointing out some memory-allocation problems. + * Pascal Hofstee : Code for wheeldrawing and calculating colors from it. + * Primary coder of this Color Panel. + * Alban Hertroys : Optimizations for algorithms for color- + * wheel. Also custom ColorPalettes and magnifying + * glass. Secondary coder ;) + * Alfredo K. Kojima : For pointing out memory-allocation problems + * and similair code-issues * Marco van Hylckama-Vlieg : For once again doing the artwork ;-) - * - * - * Changes: - * fixed absurd wstrdup() uses, gazillion memory leaks, buffer overruns etc etc + * + * small note: Tabstop size = 8 + * */ - - - #include "WINGsP.h" #include #include @@ -32,55 +31,50 @@ # define PATH_MAX 1024 #endif -#define mglass_width 20 -#define mglass_height 20 - -#define magnify_hotspot_x 17 -#define magnify_hotspot_y 10 -#define magnify_cursor_width 46 -#define magnify_cursor_height 36 -static char magnify_cursor_bits[] = { - 0xc0, 0x0f, 0x00, 0x00, 0x00, 0xc0, 0x70, 0x70, 0x00, 0x00, 0x00, 0xc0, - 0x18, 0xc0, 0x00, 0x00, 0x00, 0xc0, 0x04, 0x80, 0x01, 0x00, 0x00, 0xc0, - 0x06, 0x00, 0x01, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x02, 0x00, 0x00, 0xc0, - 0x03, 0x00, 0x02, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x06, 0x00, 0x00, 0xc0, - 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, - 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, - 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x02, 0x00, 0x00, 0xc0, - 0x02, 0x00, 0x02, 0x00, 0x00, 0xc0, 0x04, 0x00, 0x03, 0x00, 0x00, 0xc0, - 0x0c, 0x80, 0x01, 0x00, 0x00, 0xc0, 0x18, 0xc0, 0x03, 0x00, 0x00, 0xc0, - 0x70, 0x60, 0x04, 0x00, 0x00, 0xc0, 0x80, 0x1f, 0x01, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x0a, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x10, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x24, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x08, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x40, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x90, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x20, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x40, 0x01, 0x00, 0xc0, - 0x00, 0x00, 0x00, 0x02, 0x00, 0xc0, 0x00, 0x00, 0x80, 0x04, 0x00, 0xc0, - 0x00, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0}; - - -#define magnify_mask_width 46 -#define magnify_mask_height 36 -static char magnify_mask_bits[] = { - 0xc0, 0x0f, 0x00, 0x00, 0x00, 0xc0, 0x70, 0x70, 0x00, 0x00, 0x00, 0xc0, - 0x18, 0xc0, 0x00, 0x00, 0x00, 0xc0, 0x04, 0x80, 0x01, 0x00, 0x00, 0xc0, - 0x06, 0x00, 0x01, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x02, 0x00, 0x00, 0xc0, - 0x03, 0x00, 0x02, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x06, 0x00, 0x00, 0xc0, - 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, - 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, - 0x01, 0x00, 0x04, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x02, 0x00, 0x00, 0xc0, - 0x02, 0x00, 0x02, 0x00, 0x00, 0xc0, 0x04, 0x00, 0x03, 0x00, 0x00, 0xc0, - 0x0c, 0x80, 0x01, 0x00, 0x00, 0xc0, 0x18, 0xc0, 0x03, 0x00, 0x00, 0xc0, - 0x70, 0x60, 0x07, 0x00, 0x00, 0xc0, 0x80, 0x1f, 0x07, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x0e, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x1c, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x3c, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x38, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x70, 0x00, 0x00, 0xc0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0xe0, 0x00, 0x00, 0xc0, 0x00, 0x00, 0xc0, 0x01, 0x00, 0xc0, - 0x00, 0x00, 0x80, 0x03, 0x00, 0xc0, 0x00, 0x00, 0x80, 0x07, 0x00, 0xc0, - 0x00, 0x00, 0x00, 0x03, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, - 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0}; + +/* + * Bitmaps for magnifying glass cursor + */ + +/* Cursor */ +#define Cursor_x_hot 11 +#define Cursor_y_hot 11 +#define Cursor_width 32 +#define Cursor_height 32 +static unsigned char Cursor_bits[] = { + 0x00,0x7e,0x00,0x00,0xc0,0x81,0x03,0x00,0x20,0x00,0x04,0x00,0x10,0x00,0x08, + 0x00,0x08,0x00,0x10,0x00,0x04,0x00,0x20,0x00,0x02,0x00,0x40,0x00,0x02,0x00, + 0x40,0x00,0x02,0x00,0x40,0x00,0x01,0x42,0x80,0x00,0x01,0x24,0x80,0x00,0x01, + 0x00,0x80,0x00,0x01,0x00,0x80,0x00,0x01,0x24,0x80,0x00,0x01,0x42,0x80,0x00, + 0x02,0x00,0x40,0x00,0x02,0x00,0x40,0x00,0x02,0x00,0x40,0x00,0x04,0x00,0x20, + 0x00,0x08,0x00,0x50,0x00,0x10,0x00,0x88,0x00,0x20,0x00,0x5c,0x01,0xc0,0x81, + 0x3b,0x02,0x00,0x7e,0x70,0x05,0x00,0x00,0xe0,0x08,0x00,0x00,0xc0,0x15,0x00, + 0x00,0x80,0x23,0x00,0x00,0x00,0x57,0x00,0x00,0x00,0x8e,0x00,0x00,0x00,0x5c, + 0x00,0x00,0x00,0xb8,0x00,0x00,0x00,0x70}; + +/* Cursor shape-mask */ +#define Cursor_shape_width 32 +#define Cursor_shape_height 32 +static unsigned char Cursor_shape_bits[] = { + 0x00,0x7e,0x00,0x00,0xc0,0x81,0x03,0x00,0x20,0x00,0x04,0x00,0x10,0x00,0x08, + 0x00,0x08,0x00,0x10,0x00,0x04,0x00,0x20,0x00,0x02,0x00,0x40,0x00,0x02,0x00, + 0x40,0x00,0x02,0x00,0x40,0x00,0x01,0x42,0x80,0x00,0x01,0x24,0x80,0x00,0x01, + 0x00,0x80,0x00,0x01,0x00,0x80,0x00,0x01,0x24,0x80,0x00,0x01,0x42,0x80,0x00, + 0x02,0x00,0x40,0x00,0x02,0x00,0x40,0x00,0x02,0x00,0x40,0x00,0x04,0x00,0x20, + 0x00,0x08,0x00,0x70,0x00,0x10,0x00,0xf8,0x00,0x20,0x00,0xfc,0x01,0xc0,0x81, + 0xfb,0x03,0x00,0x7e,0xf0,0x07,0x00,0x00,0xe0,0x0f,0x00,0x00,0xc0,0x1f,0x00, + 0x00,0x80,0x3f,0x00,0x00,0x00,0x7f,0x00,0x00,0x00,0xfe,0x00,0x00,0x00,0xfc, + 0x00,0x00,0x00,0xf8,0x00,0x00,0x00,0x70}; + +/* Clip-mask for magnified pixels */ +#define Cursor_mask_width 22 +#define Cursor_mask_height 22 +static unsigned char Cursor_mask_bits[] = { + 0x00,0x3f,0x00,0xe0,0xff,0x01,0xf0,0xff,0x03,0xf8,0xff,0x07,0xfc,0xff,0x0f, + 0xfe,0xff,0x1f,0xfe,0xff,0x1f,0xfe,0xff,0x1f,0xff,0xff,0x3f,0xff,0xff,0x3f, + 0xff,0xff,0x3f,0xff,0xff,0x3f,0xff,0xff,0x3f,0xff,0xff,0x3f,0xfe,0xff,0x1f, + 0xfe,0xff,0x1f,0xfe,0xff,0x1f,0xfc,0xff,0x0f,0xf8,0xff,0x07,0xf0,0xff,0x03, + 0xe0,0xff,0x01,0x00,0x3f,0x00}; typedef struct MovingView { @@ -102,6 +96,9 @@ typedef struct W_ColorPanel { WMFont *font8; WMFont *font12; + void *clientData; + WMAction *action; + /* Common Stuff */ WMColorWell *colorWell; WMButton *magnifyBtn; @@ -201,19 +198,27 @@ typedef struct W_ColorPanel { char *configurationPath; struct { + unsigned int continuous:1; + unsigned int dragging:1; - unsigned int done:1; } flags; } W_ColorPanel; enum { - menuNewFromFile, - menuRename, - menuRemove, - menuCopy, - menuNewFromClipboard + CPmenuNewFromFile, + CPmenuRename, + CPmenuRemove, + CPmenuCopy, + CPmenuNewFromClipboard } customPaletteMenuItem; +enum { + CLmenuAdd, + CLmenuRename, + CLmenuRemove +} colorListMenuItem; + + #define PWIDTH 194 #define PHEIGHT 266 #define colorWheelSize 150 @@ -233,8 +238,7 @@ enum { #define RGBTXT "/usr/X11R6/lib/X11/rgb.txt" #define MAX_LENGTH 1024 -static void wAbort(); -static int fetchImageFile(char* toPath, char *imageSrcFile, char *imageDestFileName); +static int fetchFile(char* toPath, char *imageSrcFile, char *imageDestFileName); char *generateNewFilename(char *curName); static void modeButtonCallback(WMWidget *w, void *data); @@ -242,6 +246,8 @@ static int getPickerPart(W_ColorPanel *panel, int x, int y); static void readConfiguration(W_ColorPanel *panel); static void readXColors(W_ColorPanel *panel); +static void closeWindowCallback(WMWidget *w, void *data); + static Cursor magnifyGrabPointer(W_ColorPanel *panel); static WMPoint magnifyInitialize(W_ColorPanel *panel); static void magnifyPutCursor(WMWidget *w, void *data); @@ -299,6 +305,9 @@ static void customPaletteMenuRemove(W_ColorPanel *panel); static void colorListPaintItem(WMList *lPtr, int index, Drawable d, char *text, int state, WMRect *rect); static void colorListSelect(WMWidget *w, void *data); +static void colorListColorMenuCallback(WMWidget *w, void *data); +static void colorListListMenuCallback(WMWidget *w, void *data); +static void colorListListMenuNew(W_ColorPanel *panel); static void wheelInit(W_ColorPanel *panel); static void grayInit(W_ColorPanel *panel); @@ -307,12 +316,16 @@ static void cmykInit(W_ColorPanel *panel); static void hsbInit(W_ColorPanel *panel); -static void -wAbort () + +void +WMSetColorPanelAction(WMColorPanel *panel, WMAction *action, void *data) { - exit(1); + panel->action = action; + panel->clientData = data; } + + static WMColorPanel* makeColorPanel(WMScreen *scrPtr, char *name) { @@ -335,8 +348,8 @@ makeColorPanel(WMScreen *scrPtr, char *name) panel->win = WMCreateWindowWithStyle(scrPtr, name, WMTitledWindowMask | WMClosableWindowMask | WMResizableWindowMask); WMResizeWidget(panel->win, PWIDTH, PHEIGHT); WMSetWindowTitle(panel->win, "Colors"); - - + WMSetWindowCloseAction(panel->win, closeWindowCallback, panel); + /* Set Default ColorPanel Mode(s) */ panel->mode = WMWheelModeColorPanel; panel->lastChanged = WMWheelModeColorPanel; @@ -349,13 +362,12 @@ makeColorPanel(WMScreen *scrPtr, char *name) WSetColorWellBordered(panel->colorWell, False); WMMoveWidget(panel->colorWell, 56, 4); - panel->magnifyBtn = WMCreateCommandButton(panel->win); + panel->magnifyBtn = WMCreateCustomButton(panel->win, WBBStateLightMask|WBBStateChangeMask); WMResizeWidget(panel->magnifyBtn, 46, 36); WMMoveWidget(panel->magnifyBtn, 6,4); WMSetButtonAction(panel->magnifyBtn, magnifyPutCursor, panel); WMSetButtonImagePosition(panel->magnifyBtn, WIPImageOnly); WMSetButtonImage(panel->magnifyBtn, scrPtr->magnifyIcon); - WMSetButtonAltImage(panel->magnifyBtn, scrPtr->altMagnifyIcon); panel->wheelBtn = WMCreateCustomButton(panel->win, WBBStateLightMask|WBBStateChangeMask); WMResizeWidget(panel->wheelBtn, 46, 32); @@ -503,7 +515,7 @@ makeColorPanel(WMScreen *scrPtr, char *name) image = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); pixmap = WMCreatePixmapFromRImage(scrPtr, image, 0); RDestroyImage(image); - W_PaintText(W_VIEW(panel->grayBrightnessS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scrPtr->white), False, "Brightness", strlen("Brightness")); + W_PaintText(W_VIEW(panel->grayBrightnessS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scrPtr->white), False, "Brightness", strlen("Brightness")); WMSetSliderImage(panel->grayBrightnessS, pixmap); WMReleasePixmap(pixmap); @@ -571,7 +583,7 @@ WMTextDidEndEditingNotification, panel->grayBrightnessT); image = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); pixmap = WMCreatePixmapFromRImage(scrPtr, image, 0); - W_PaintText(W_VIEW(panel->rgbRedS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scrPtr->white), False, "Red", strlen("Red")); + W_PaintText(W_VIEW(panel->rgbRedS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scrPtr->white), False, "Red", strlen("Red")); RDestroyImage(image); WMSetSliderImage(panel->rgbRedS, pixmap); WMReleasePixmap(pixmap); @@ -580,8 +592,9 @@ WMTextDidEndEditingNotification, panel->grayBrightnessT); WMResizeWidget(panel->rgbRedT, 40, 18); WMMoveWidget(panel->rgbRedT, 146, 13); WMSetTextFieldAlignment(panel->rgbRedT, WALeft); - WMAddNotificationObserver(rgbTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->rgbRedT); + WMAddNotificationObserver(rgbTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->rgbRedT); panel->rgbGreenS = WMCreateSlider(panel->rgbFrm); @@ -598,7 +611,7 @@ WMTextDidEndEditingNotification, panel->rgbRedT); image = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); pixmap = WMCreatePixmapFromRImage(scrPtr, image, 0); - W_PaintText(W_VIEW(panel->rgbGreenS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scrPtr->white), False, "Green", strlen("Green")); + W_PaintText(W_VIEW(panel->rgbGreenS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scrPtr->white), False, "Green", strlen("Green")); RDestroyImage(image); WMSetSliderImage(panel->rgbGreenS, pixmap); WMReleasePixmap(pixmap); @@ -607,8 +620,9 @@ WMTextDidEndEditingNotification, panel->rgbRedT); WMResizeWidget(panel->rgbGreenT, 40, 18); WMMoveWidget(panel->rgbGreenT, 146, 35); WMSetTextFieldAlignment(panel->rgbGreenT, WALeft); - WMAddNotificationObserver(rgbTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->rgbGreenT); + WMAddNotificationObserver(rgbTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->rgbGreenT); panel->rgbBlueS = WMCreateSlider(panel->rgbFrm); @@ -625,7 +639,7 @@ WMTextDidEndEditingNotification, panel->rgbGreenT); image = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); pixmap = WMCreatePixmapFromRImage(scrPtr, image, 0); - W_PaintText(W_VIEW(panel->rgbBlueS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scrPtr->white), False, "Blue", strlen("Blue")); + W_PaintText(W_VIEW(panel->rgbBlueS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scrPtr->white), False, "Blue", strlen("Blue")); RDestroyImage(image); WMSetSliderImage(panel->rgbBlueS, pixmap); WMReleasePixmap(pixmap); @@ -634,8 +648,9 @@ WMTextDidEndEditingNotification, panel->rgbGreenT); WMResizeWidget(panel->rgbBlueT, 40, 18); WMMoveWidget(panel->rgbBlueT, 146, 57); WMSetTextFieldAlignment(panel->rgbBlueT, WALeft); - WMAddNotificationObserver(rgbTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->rgbBlueT); + WMAddNotificationObserver(rgbTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->rgbBlueT); /* End of RGB Panel */ /* Widgets for CMYK Panel */ @@ -678,7 +693,7 @@ WMTextDidEndEditingNotification, panel->rgbBlueT); image = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); pixmap = WMCreatePixmapFromRImage(scrPtr, image, 0); - W_PaintText(W_VIEW(panel->cmykCyanS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scrPtr->black), False, "Cyan", strlen("Cyan")); + W_PaintText(W_VIEW(panel->cmykCyanS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scrPtr->black), False, "Cyan", strlen("Cyan")); RDestroyImage(image); WMSetSliderImage(panel->cmykCyanS, pixmap); WMReleasePixmap(pixmap); @@ -687,9 +702,9 @@ WMTextDidEndEditingNotification, panel->rgbBlueT); WMResizeWidget(panel->cmykCyanT, 40, 18); WMMoveWidget(panel->cmykCyanT, 146, 13); WMSetTextFieldAlignment(panel->cmykCyanT, WALeft); - WMAddNotificationObserver(cmykTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->cmykCyanT); - + WMAddNotificationObserver(cmykTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->cmykCyanT); panel->cmykMagentaS = WMCreateSlider(panel->cmykFrm); WMResizeWidget(panel->cmykMagentaS, 141, 16); @@ -705,7 +720,7 @@ WMTextDidEndEditingNotification, panel->cmykCyanT); image = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); pixmap = WMCreatePixmapFromRImage(scrPtr, image, 0); - W_PaintText(W_VIEW(panel->cmykMagentaS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scrPtr->black), False, "Magenta", strlen("Magenta")); + W_PaintText(W_VIEW(panel->cmykMagentaS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scrPtr->black), False, "Magenta", strlen("Magenta")); RDestroyImage(image); WMSetSliderImage(panel->cmykMagentaS, pixmap); WMReleasePixmap(pixmap); @@ -714,8 +729,9 @@ WMTextDidEndEditingNotification, panel->cmykCyanT); WMResizeWidget(panel->cmykMagentaT, 40, 18); WMMoveWidget(panel->cmykMagentaT, 146, 35); WMSetTextFieldAlignment(panel->cmykMagentaT, WALeft); - WMAddNotificationObserver(cmykTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->cmykMagentaT); + WMAddNotificationObserver(cmykTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->cmykMagentaT); panel->cmykYellowS = WMCreateSlider(panel->cmykFrm); @@ -732,7 +748,7 @@ WMTextDidEndEditingNotification, panel->cmykMagentaT); image = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); pixmap = WMCreatePixmapFromRImage(scrPtr, image, 0); - W_PaintText(W_VIEW(panel->cmykYellowS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scrPtr->black), False, "Yellow", strlen("Yellow")); + W_PaintText(W_VIEW(panel->cmykYellowS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scrPtr->black), False, "Yellow", strlen("Yellow")); RDestroyImage(image); WMSetSliderImage(panel->cmykYellowS, pixmap); WMReleasePixmap(pixmap); @@ -741,9 +757,9 @@ WMTextDidEndEditingNotification, panel->cmykMagentaT); WMResizeWidget(panel->cmykYellowT, 40, 18); WMMoveWidget(panel->cmykYellowT, 146, 57); WMSetTextFieldAlignment(panel->cmykYellowT, WALeft); - WMAddNotificationObserver(cmykTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->cmykYellowT); - + WMAddNotificationObserver(cmykTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->cmykYellowT); panel->cmykBlackS = WMCreateSlider(panel->cmykFrm); WMResizeWidget(panel->cmykBlackS, 141, 16); @@ -760,7 +776,7 @@ WMTextDidEndEditingNotification, panel->cmykYellowT); image = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); pixmap = WMCreatePixmapFromRImage(scrPtr, image, 0); - W_PaintText(W_VIEW(panel->cmykBlackS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scrPtr->black), False, "Black", strlen("Black")); + W_PaintText(W_VIEW(panel->cmykBlackS), pixmap->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scrPtr->black), False, "Black", strlen("Black")); RDestroyImage(image); WMSetSliderImage(panel->cmykBlackS, pixmap); WMReleasePixmap(pixmap); @@ -769,8 +785,9 @@ WMTextDidEndEditingNotification, panel->cmykYellowT); WMResizeWidget(panel->cmykBlackT, 40, 18); WMMoveWidget(panel->cmykBlackT, 146, 79); WMSetTextFieldAlignment(panel->cmykBlackT, WALeft); - WMAddNotificationObserver(cmykTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->cmykBlackT); + WMAddNotificationObserver(cmykTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->cmykBlackT); /* End of CMYK Panel */ /* Widgets for HSB Panel */ @@ -791,9 +808,9 @@ WMTextDidEndEditingNotification, panel->cmykBlackT); WMResizeWidget(panel->hsbHueT, 40, 18); WMMoveWidget(panel->hsbHueT, 146, 13); WMSetTextFieldAlignment(panel->hsbHueT, WALeft); - WMAddNotificationObserver(hsbTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->hsbHueT); - + WMAddNotificationObserver(hsbTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->hsbHueT); panel->hsbSaturationS = WMCreateSlider(panel->hsbFrm); WMResizeWidget(panel->hsbSaturationS, 141, 16); @@ -807,9 +824,9 @@ WMTextDidEndEditingNotification, panel->hsbHueT); WMResizeWidget(panel->hsbSaturationT, 40, 18); WMMoveWidget(panel->hsbSaturationT, 146, 35); WMSetTextFieldAlignment(panel->hsbSaturationT, WALeft); - WMAddNotificationObserver(hsbTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->hsbSaturationT); - + WMAddNotificationObserver(hsbTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->hsbSaturationT); panel->hsbBrightnessS = WMCreateSlider(panel->hsbFrm); WMResizeWidget(panel->hsbBrightnessS, 141, 16); @@ -823,8 +840,9 @@ WMTextDidEndEditingNotification, panel->hsbSaturationT); WMResizeWidget(panel->hsbBrightnessT, 40, 18); WMMoveWidget(panel->hsbBrightnessT, 146, 57); WMSetTextFieldAlignment(panel->hsbBrightnessT, WALeft); - WMAddNotificationObserver(hsbTextFieldCallback, panel, \ -WMTextDidEndEditingNotification, panel->hsbBrightnessT); + WMAddNotificationObserver(hsbTextFieldCallback, panel, + WMTextDidEndEditingNotification, + panel->hsbBrightnessT); /* End of HSB Panel */ @@ -866,16 +884,16 @@ WMTextDidEndEditingNotification, panel->hsbBrightnessT); WMResizeWidget(panel->customPaletteMenuBtn, PWIDTH - 8, 20); WMMoveWidget(panel->customPaletteMenuBtn, 0, PHEIGHT - 130); - WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "New from File..."); /* item 0 */ - WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "Rename..."); /* item 1 */ - WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "Remove"); /* item 2 */ - WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "Copy"); /* item 3 */ - WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "New from Clipboard"); /* item 4 */ + WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "New from File..."); + WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "Rename..."); + WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "Remove"); + WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "Copy"); + WMAddPopUpButtonItem(panel->customPaletteMenuBtn, "New from Clipboard"); - WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, 1, 0); - WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, 2, 0); - WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, 3, 0); - WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, 4, 0); + WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, CPmenuRename, 0); + WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, CPmenuRemove, 0); + WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, CPmenuCopy, 0); + WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, CPmenuNewFromClipboard, 0); customRenderSpectrum(panel); panel->currentPalette = 0; @@ -904,17 +922,31 @@ WMTextDidEndEditingNotification, panel->hsbBrightnessT); panel->colorListColorMenuBtn = WMCreatePopUpButton(panel->colorListFrm); WMSetPopUpButtonPullsDown(panel->colorListColorMenuBtn, 1); WMSetPopUpButtonText(panel->colorListColorMenuBtn, "Color"); - /* WMSetPopUpButtonAction(panel->colorListColorMenuBtn, colorListColorMenuCallback, panel); */ + WMSetPopUpButtonAction(panel->colorListColorMenuBtn, colorListColorMenuCallback, panel); WMResizeWidget(panel->colorListColorMenuBtn, (PWIDTH - 16)/2, 20); WMMoveWidget(panel->colorListColorMenuBtn, 0, PHEIGHT - 130); + WMAddPopUpButtonItem(panel->colorListColorMenuBtn, "Add..."); + WMAddPopUpButtonItem(panel->colorListColorMenuBtn, "Rename..."); + WMAddPopUpButtonItem(panel->colorListColorMenuBtn, "Remove"); + + WMSetPopUpButtonItemEnabled(panel->colorListColorMenuBtn, CLmenuAdd, 0); + WMSetPopUpButtonItemEnabled(panel->colorListColorMenuBtn, CLmenuRename, 0); + WMSetPopUpButtonItemEnabled(panel->colorListColorMenuBtn, CLmenuRemove, 0); + panel->colorListListMenuBtn = WMCreatePopUpButton(panel->colorListFrm); WMSetPopUpButtonPullsDown(panel->colorListListMenuBtn, 1); WMSetPopUpButtonText(panel->colorListListMenuBtn, "List"); - /* WMSetPopUpButtonAction(panel->colorListListMenuBtn, colorListListMenuCallback, panel); */ + WMSetPopUpButtonAction(panel->colorListListMenuBtn, colorListListMenuCallback, panel); WMResizeWidget(panel->colorListListMenuBtn, (PWIDTH - 16)/2, 20); WMMoveWidget(panel->colorListListMenuBtn, (PWIDTH - 16)/2 + 8, PHEIGHT - 130); + WMAddPopUpButtonItem(panel->colorListListMenuBtn, "New..."); + WMAddPopUpButtonItem(panel->colorListListMenuBtn, "Rename..."); + WMAddPopUpButtonItem(panel->colorListListMenuBtn, "Remove"); + + WMSetPopUpButtonItemEnabled(panel->colorListListMenuBtn, CLmenuRename, 0); + WMSetPopUpButtonItemEnabled(panel->colorListListMenuBtn, CLmenuRemove, 0); WMRealizeWidget(panel->win); WMMapSubwidgets(panel->win); @@ -988,25 +1020,31 @@ WMFreeColorPanel(WMColorPanel *panel) } -int -WMRunColorPanel(WMColorPanel *panel, WMWindow *owner, RColor color) +void +WMCloseColorPanel(WMColorPanel *panel) +{ + WMCloseWindow(panel->win); +} + + +void +WMShowColorPanel(WMColorPanel *panel) { WMScreen *scr = WMWidgetScreen(panel->win); XEvent event; RHSVColor hsvcolor; - GC bgc = W_GC(scr->black); - GC wgc = W_GC(scr->white); - float W_PI = 4*atan(1); - - WMChangePanelOwner(panel->win, owner); - - WMSetColorPanelColor(panel, color); + GC bgc = WMColorGC(scr->black); + GC wgc = WMColorGC(scr->white); + RColor color; + panel->wheelMtrx = wheelInitMatrix(panel); /* Needs to be done After Color is set */ + + /* Maybe put this in sub-function ... Initialising selection images */ RRGBtoHSV(&color, &hsvcolor); - panel->colx = 2 + rint((colorWheelSize / 2.0) * (1 + (hsvcolor.saturation/255.0) * cos( hsvcolor.hue*W_PI/180.0))); - panel->coly = 2 + rint((colorWheelSize / 2.0) * (1 + (hsvcolor.saturation/255.0) * sin(-hsvcolor.hue*W_PI/180.0))); + panel->colx = 2 + rint((colorWheelSize / 2.0) * (1 + (hsvcolor.saturation/255.0) * cos( hsvcolor.hue*M_PI/180.0))); + panel->coly = 2 + rint((colorWheelSize / 2.0) * (1 + (hsvcolor.saturation/255.0) * sin(-hsvcolor.hue*M_PI/180.0))); wheelUpdateBrightnessGradientFromHSV(panel, hsvcolor); WMSetSliderValue(panel->wheelBrightnessS, 255 - hsvcolor.value); @@ -1018,23 +1056,20 @@ WMRunColorPanel(WMColorPanel *panel, WMWindow *owner, RColor color) panel->palx = customPaletteWidth/2; panel->paly = customPaletteHeight/2; - WMSetPickerMode(panel, WMWheelModeColorPanel); - - panel->flags.done = 0; - + WMSetColorPanelPickerMode(panel, WMWheelModeColorPanel); + WMMapWidget(panel->win); - - while (!panel->flags.done) { - WMNextEvent(scr->display, &event); - WMHandleEvent(&event); - } - - WMCloseWindow(panel->win); - - return 0; } +static void +closeWindowCallback(WMWidget *w, void *data) +{ + W_ColorPanel *panel = (W_ColorPanel*)data; + + WMCloseWindow(panel->win); +} + static void readConfiguration(W_ColorPanel *panel) @@ -1049,8 +1084,10 @@ readConfiguration(W_ColorPanel *panel) if (stat(panel->configurationPath, &stat_buf)!=0) { if (mkdir(panel->configurationPath, S_IRWXU|S_IRGRP|S_IROTH|S_IXGRP|S_IXOTH)!=0) { wsyserror("ColorPanel could not create directory %s needed to store configurations", panel->configurationPath); - WMFreeColorPanel(panel); - wAbort(); + WMSetPopUpButtonEnabled(panel->customPaletteMenuBtn, False); + WMSetPopUpButtonEnabled(panel->colorListColorMenuBtn, False); + WMSetPopUpButtonEnabled(panel->colorListListMenuBtn, False); + WMRunAlertPanel(WMWidgetScreen(panel->win), panel->win, "File Error", "Could not create ColorPanel configuration directory", "OK", NULL, NULL); } return; } @@ -1102,7 +1139,7 @@ readXColors(W_ColorPanel *panel) void -WMSetPickerMode(WMColorPanel *panel, WMColorPanelMode mode) +WMSetColorPanelPickerMode(WMColorPanel *panel, WMColorPanelMode mode) { W_Screen *scr = WMWidgetScreen(panel->win); @@ -1188,58 +1225,45 @@ WMSetPickerMode(WMColorPanel *panel, WMColorPanelMode mode) panel->mode = mode; } + void WMSetColorPanelColor(WMColorPanel *panel, RColor color) { - WMScreen *scr = WMWidgetScreen(panel->win); - WMColor *wellcolor; - int originalHue; - - wellcolor = WMCreateRGBColor(scr, color.red << 8, color.green << 8, color.blue << 8, True); - WMSetColorWellColor(panel->colorWell, wellcolor); - WMReleaseColor(wellcolor); - - panel->color = color; - - /* If color was set by HSB-Panel do not convert back to hsv */ - if (panel->lastChanged != WMHSBModeColorPanel) { - - /* if color is black, hue is undetermined, so it must be restored */ - if ((panel->color.red == 0) && - (panel->color.green == 0) && - (panel->color.blue == 0) && - (panel->hsvcolor.hue <= 359)) - { - originalHue = panel->hsvcolor.hue; - RRGBtoHSV(&panel->color, &panel->hsvcolor); - panel->hsvcolor.hue = originalHue; - } else { - RRGBtoHSV(&panel->color, &panel->hsvcolor); - } +return; +} + + +static void +updateSwatch(WMColorPanel *panel, RColor color) +{ + WMSetColorPanelColor(panel, color); + if (panel->action && (!panel->flags.dragging || panel->flags.continuous)) { + (*panel->action)(panel, panel->clientData); } } + static void modeButtonCallback(WMWidget *w, void *data) { W_ColorPanel *panel = (W_ColorPanel*)(data); if (w == panel->wheelBtn) - WMSetPickerMode(panel, WMWheelModeColorPanel); + WMSetColorPanelPickerMode(panel, WMWheelModeColorPanel); else if (w == panel->slidersBtn) - WMSetPickerMode(panel, panel->slidersmode); + WMSetColorPanelPickerMode(panel, panel->slidersmode); else if (w == panel->customPaletteBtn) - WMSetPickerMode(panel, WMCustomPaletteModeColorPanel); + WMSetColorPanelPickerMode(panel, WMCustomPaletteModeColorPanel); else if (w == panel->colorListBtn) - WMSetPickerMode(panel, WMColorListModeColorPanel); + WMSetColorPanelPickerMode(panel, WMColorListModeColorPanel); else if (w == panel->grayBtn) - WMSetPickerMode(panel, WMGrayModeColorPanel); + WMSetColorPanelPickerMode(panel, WMGrayModeColorPanel); else if (w == panel->rgbBtn) - WMSetPickerMode(panel, WMRGBModeColorPanel); + WMSetColorPanelPickerMode(panel, WMRGBModeColorPanel); else if (w == panel->cmykBtn) - WMSetPickerMode(panel, WMCMYKModeColorPanel); + WMSetColorPanelPickerMode(panel, WMCMYKModeColorPanel); else if (w == panel->hsbBtn) - WMSetPickerMode(panel, WMHSBModeColorPanel); + WMSetColorPanelPickerMode(panel, WMHSBModeColorPanel); } @@ -1252,37 +1276,39 @@ magnifyGetImage(WMScreen *scr, int x, int y) int x0, y0, w0, h0; int displayWidth = DisplayWidth(scr->display, scr->screen); int displayHeight = DisplayHeight(scr->display, scr->screen); + const int half_mask_width = (Cursor_mask_width +1)/2; + const int half_mask_height = (Cursor_mask_height +1)/2; /* Coordinate correction for back pixmap */ - x0 = 0; y0 = 0; w0 = mglass_width; h0 = mglass_height; + x0 = 0; y0 = 0; w0 = Cursor_mask_width; h0 = Cursor_mask_height; - if (x < mglass_width/2) { + if (x < half_mask_width) { if (x < 0) x = 0; - x0 = mglass_width/2 - x; - w0 = mglass_width - x0; + x0 = half_mask_width - x; + w0 = Cursor_mask_width - x0; } - if (x > displayWidth - (mglass_width+1)/2) { + if (x > displayWidth - half_mask_width) { if (x > displayWidth) x = displayWidth; - w0 = mglass_width - ((mglass_width+1)/2 - (displayWidth - x)); + w0 = Cursor_mask_width - (half_mask_width - (displayWidth - x)); } - if (y < mglass_height/2) { + if (y < half_mask_height) { if (y < 0) y = 0; - y0 = mglass_height/2 - y; - h0 = mglass_height - y0; + y0 = half_mask_height - y; + h0 = Cursor_mask_height - y0; } - if (y > displayHeight - (mglass_height+1)/2) { + if (y > displayHeight - half_mask_height) { if (y > displayHeight) y = displayHeight; - h0 = mglass_height - ((mglass_height+1)/2 - (displayHeight - y)); + h0 = Cursor_mask_height - (half_mask_height - (displayHeight - y)); } - image = XGetImage(scr->display, scr->rootWin, x + x0 - mglass_width/2, - y + y0 - mglass_height/2, w0, h0, AllPlanes, ZPixmap); + image = XGetImage(scr->display, scr->rootWin, x + x0 - Cursor_x_hot, + y + y0 - Cursor_y_hot, w0, h0, AllPlanes, ZPixmap); - pixmap = XCreatePixmap(scr->display, W_DRAWABLE(scr), - mglass_width, mglass_height, scr->depth); + pixmap = XCreatePixmap(scr->display, W_DRAWABLE(scr), Cursor_mask_width, + Cursor_mask_height, scr->depth); XPutImage(scr->display, pixmap, scr->copyGC, image, 0, 0, x0, y0, w0, h0); return pixmap; @@ -1317,14 +1343,15 @@ magnifyGetStorePixmap(WMColorPanel *panel, int x1, int y1, int x2, int y2) yb = y1 - y2; } - w = mglass_width - abs(x1-x2); - h = mglass_height - abs(y1-y2); + w = Cursor_mask_width - abs(x1-x2); + h = Cursor_mask_height - abs(y1-y2); /* Get pixmap from screen */ pixmap = magnifyGetImage(scr, x2, y2); /* Copy previously stored pixmap on covered part of above pixmap */ - if (panel->magnifyGlass->valid) { + if (panel->magnifyGlass->valid) + { XCopyArea(scr->display, panel->magnifyGlass->pixmap, pixmap, scr->copyGC, xa, ya, w, h, xb, yb); @@ -1346,35 +1373,35 @@ magnifyCreatePixmap(WMColorPanel *panel) Pixmap magPix; Pixmap backPix; RImage *pixelImg; + const int half_mask_width = Cursor_mask_width/2; + const int half_mask_height = Cursor_mask_height/2; + /* * Get image */ /* Rectangle that's going to be the background */ - backPix = XCreatePixmap(scr->display, W_DRAWABLE(scr), mglass_width, - mglass_height, scr->depth); + backPix = XCreatePixmap(scr->display, W_DRAWABLE(scr), Cursor_mask_width, + Cursor_mask_height , scr->depth); XCopyArea(scr->display, panel->magnifyGlass->pixmap, backPix, scr->copyGC, - 0, 0, mglass_width, mglass_height, 0, 0); + 0, 0, Cursor_mask_width, Cursor_mask_height, 0, 0); /* * Magnify image */ - magPix = XCreatePixmap(scr->display, W_DRAWABLE(scr), mglass_width, - mglass_height, scr->depth); + magPix = XCreatePixmap(scr->display, W_DRAWABLE(scr), Cursor_mask_width +2, + Cursor_mask_height +2, scr->depth); - for (u=0; u<=3; u++) - for (v=0; v<=3; v++) - for (i=u*6; i < (u+1)*6; i++) - for (j=v*6; j < (v+1)*6; j++) - if (((i >= 0) && (i < mglass_width)) - && ((j >= 0) && (j < mglass_height))) - XCopyArea(scr->display, backPix, magPix, scr->copyGC, - u + 4, v + 4, 1, 1, i, j); + for (u=0; u<5+1; u++) /* Copy an area of 5x5 pixels from the center */ + for (v=0; v<5+1; v++) + for (i=u*5; i < (u+1)*5; i++) /* magnify it 5 times */ + for (j=v*5; j < (v+1)*5; j++) + XCopyArea(scr->display, backPix, magPix, scr->copyGC, u +9, v +9, 1, 1, i, j); /* Get color under hotspot */ - ofs = mglass_width/2 + (mglass_height/2)*mglass_width; + ofs = half_mask_width + half_mask_height * Cursor_mask_width; pixelImg = RCreateImageFromDrawable(scr->rcontext, backPix, backPix); panel->magnifyGlass->color.red = pixelImg->data[0][ofs]; panel->magnifyGlass->color.green = pixelImg->data[1][ofs]; @@ -1385,11 +1412,11 @@ magnifyCreatePixmap(WMColorPanel *panel) XSetClipMask(scr->display, scr->clipGC, panel->magnifyGlass->mask); XSetClipOrigin(scr->display, scr->clipGC, 0, 0); - XCopyArea(scr->display, magPix, backPix, scr->clipGC, 0, 0, - mglass_width, mglass_height, 0, 0); - + XCopyArea(scr->display, magPix, backPix, scr->clipGC, 2, 2, Cursor_mask_width, + Cursor_mask_height, 0, 0); /* (2,2) puts center pixel on center of glass */ + XFreePixmap(scr->display, magPix); - + return backPix; } @@ -1403,7 +1430,7 @@ magnifyCreateView(W_ColorPanel *panel) magView = W_CreateTopView(scr); magView->self = panel; - W_ResizeView(magView, mglass_width, mglass_height); + W_ResizeView(magView, Cursor_mask_width, Cursor_mask_height); magView->attribFlags |= CWOverrideRedirect | CWSaveUnder; magView->attribs.event_mask = StructureNotifyMask; @@ -1420,30 +1447,26 @@ magnifyCreateView(W_ColorPanel *panel) static Cursor magnifyGrabPointer(W_ColorPanel *panel) { - W_Screen *scr = WMWidgetScreen(panel->win); - Pixmap magPixmap; - Pixmap magPixmap2; - Cursor magCursor; - XColor fgColor = {0,0,0,0,DoRed|DoGreen|DoBlue}; - XColor bgColor = {0,0xbd00,0xa500,0x5200,DoRed|DoGreen|DoBlue}; - + W_Screen *scr = WMWidgetScreen(panel->win); + Pixmap magPixmap, magPixmap2; + Cursor magCursor; + XColor fgColor = {0, 0,0,0, DoRed|DoGreen|DoBlue}; + XColor bgColor = {0, 0xbf00, 0xa000, 0x5000, DoRed|DoGreen|DoBlue}; + /* Cursor creation stuff */ magPixmap = XCreatePixmapFromBitmapData(scr->display, W_DRAWABLE(scr), - magnify_cursor_bits, - magnify_cursor_width, - magnify_cursor_height, 1, 0, 1); + Cursor_bits, Cursor_width, Cursor_height, 1, 0, 1); magPixmap2 = XCreatePixmapFromBitmapData(scr->display, W_DRAWABLE(scr), - magnify_mask_bits, - magnify_mask_width, - magnify_mask_height, 1, 0, 1); - magCursor = XCreatePixmapCursor(scr->display, magPixmap, magPixmap2, - &fgColor, &bgColor, magnify_hotspot_x, - magnify_hotspot_y); + Cursor_shape_bits, Cursor_width, Cursor_height, 1, 0, 1); + + magCursor = XCreatePixmapCursor(scr->display, magPixmap, magPixmap2, + &fgColor, &bgColor, Cursor_x_hot, Cursor_y_hot); + XFreePixmap(scr->display, magPixmap); XFreePixmap(scr->display, magPixmap2); - + XRecolorCursor(scr->display, magCursor, &fgColor, &bgColor); - + /* Set up Pointer */ XGrabPointer (scr->display, panel->magnifyGlass->view->window, True, PointerMotionMask | ButtonPressMask, @@ -1453,6 +1476,7 @@ magnifyGrabPointer(W_ColorPanel *panel) return magCursor; } + static WMPoint magnifyInitialize(W_ColorPanel *panel) { @@ -1467,10 +1491,9 @@ magnifyInitialize(W_ColorPanel *panel) /* Clipmask to make magnified view-contents circular */ - panel->magnifyGlass->mask = - XCreatePixmapFromBitmapData(scr->display, W_DRAWABLE(scr), - magnify_mask_bits, mglass_width, - mglass_height, 1, 0, 1); + panel->magnifyGlass->mask = XCreatePixmapFromBitmapData(scr->display, + W_DRAWABLE(scr), Cursor_mask_bits, + Cursor_mask_width, Cursor_mask_height, 1, 0, 1); /* Draw initial magnified part */ panel->magnifyGlass->valid = False; @@ -1479,11 +1502,9 @@ magnifyInitialize(W_ColorPanel *panel) panel->magnifyGlass->valid = True; pixmap = magnifyCreatePixmap(panel); - W_MoveView(panel->magnifyGlass->view, x - magnify_hotspot_x, - y - magnify_hotspot_y); - - XSetWindowBackgroundPixmap(scr->display, panel->magnifyGlass->view->window, - pixmap); + W_MoveView(panel->magnifyGlass->view, x - Cursor_x_hot +1, y - Cursor_y_hot +1); + + XSetWindowBackgroundPixmap(scr->display, panel->magnifyGlass->view->window, pixmap); XClearWindow(scr->display, panel->magnifyGlass->view->window); XFlush(scr->display); @@ -1507,6 +1528,13 @@ magnifyPutCursor(WMWidget *w, void *data) XEvent event; WMPoint initialPosition; + /* Destroy wheelBackImg, so it'll update properly */ + if (panel->selectionBackImg) { + XFreePixmap(WMWidgetScreen(panel->win)->display, panel->selectionBackImg); + panel->selectionBackImg = None; + } + + /* Create magnifying glass */ panel->magnifyGlass = wmalloc(sizeof(MovingView)); panel->magnifyGlass->view = magnifyCreateView(panel); @@ -1525,7 +1553,7 @@ magnifyPutCursor(WMWidget *w, void *data) { case ButtonPress: if (event.xbutton.button == Button1) { - WMSetColorPanelColor(panel, panel->magnifyGlass->color); + updateSwatch(panel, panel->magnifyGlass->color); switch (panel->mode) { case WMWheelModeColorPanel: wheelInit(panel); @@ -1557,28 +1585,24 @@ magnifyPutCursor(WMWidget *w, void *data) case MotionNotify: /* Get a "dirty rectangle" */ panel->magnifyGlass->pixmap = magnifyGetStorePixmap( - panel, x, y, /* Cool, a circular reference ! */ - event.xmotion.x_root, - event.xmotion.y_root); /* also free's magnifyGlass->pixmap */ + panel, x+1, y+1, /* Cool, a circular reference ! */ + event.xmotion.x_root+1, event.xmotion.y_root+1); /* also free's magnifyGlass->pixmap */ /* Update coordinates */ x = event.xmotion.x_root; y = event.xmotion.y_root; /* Move view */ - W_MoveView(panel->magnifyGlass->view, x - magnify_hotspot_x, - y - magnify_hotspot_y); - + W_MoveView(panel->magnifyGlass->view, x - Cursor_x_hot +1, y - Cursor_y_hot +1); + /* Put new image (with magn.) in view */ pixmap = magnifyCreatePixmap(panel); - XSetWindowBackgroundPixmap(scr->display, - panel->magnifyGlass->view->window, - pixmap); + XSetWindowBackgroundPixmap(scr->display, panel->magnifyGlass->view->window, pixmap); XClearWindow(scr->display, panel->magnifyGlass->view->window); - + XFreePixmap(scr->display, pixmap); break; - + default: WMHandleEvent(&event); break; @@ -1664,7 +1688,6 @@ wheelInitMatrix(W_ColorPanel *panel) float hue; int sat; float xcor, ycor; - float W_PI = 4 *atan(1); int dhue[4]; matrix = wheelCreateMatrix(colorWheelSize+4, colorWheelSize+4); @@ -1709,22 +1732,22 @@ wheelInitMatrix(W_ColorPanel *panel) hue = atan(ycor/xcor); else { if (ycor > 0) - hue = W_PI * 0.5; + hue = M_PI * 0.5; else - hue = W_PI * 1.5; + hue = M_PI * 1.5; } if (xcor < 0) - hue += W_PI; + hue += M_PI; if ((xcor > 0) && (ycor < 0)) - hue += W_PI * 2.0; + hue += M_PI * 2.0; hue = -hue; /* Reverse direction of ColorWheel */ if (hue < 0) - hue += W_PI * 2.0; + hue += M_PI * 2.0; - dhue[0] = (hue*360) / (W_PI * 2.0); + dhue[0] = (hue*360) / (M_PI * 2.0); for (i = 0; i < 4; i++) { @@ -1875,6 +1898,10 @@ wheelHandleActionEvents(XEvent *event, void *data) case ButtonRelease: panel->flags.dragging = 0; + if (!panel->flags.continuous) { + if (panel->action) + (*panel->action)(panel->action, panel->clientData); + } break; case MotionNotify: @@ -1969,7 +1996,7 @@ wheelUpdateSelection(W_ColorPanel *panel) { W_Screen *scr = WMWidgetScreen(panel->win); - WMSetColorPanelColor(panel, panel->color); + updateSwatch(panel, panel->color); panel->lastChanged = WMWheelModeColorPanel; /* Redraw color selector (and make a backup of the part it will cover) */ @@ -2013,7 +2040,6 @@ wheelPositionSelectionOutBounds(W_ColorPanel *panel, int x, int y) RHSVColor cur_hsv; float hue; float xcor, ycor; - float W_PI = 4*atan(1); xcor = ((x*2.0) / (colorWheelSize+4)) - 1.0; ycor = ((y*2.0) / (colorWheelSize+4)) - 1.0; @@ -2025,28 +2051,28 @@ wheelPositionSelectionOutBounds(W_ColorPanel *panel, int x, int y) hue = atan(ycor/xcor); else { if (ycor > 0) - hue = W_PI * 0.5; + hue = M_PI * 0.5; else - hue = W_PI * 1.5; + hue = M_PI * 1.5; } if (xcor < 0) - hue += W_PI; + hue += M_PI; if ((xcor > 0) && (ycor < 0)) - hue += W_PI * 2.0; + hue += M_PI * 2.0; hue = -hue; if (hue < 0) - hue += W_PI * 2.0; + hue += M_PI * 2.0; - cur_hsv.hue = (hue*360.0)/(W_PI*2.0); + cur_hsv.hue = (hue*180.0)/(M_PI); RHSVtoRGB(&cur_hsv, &panel->color); wheelUndrawSelection(panel); - panel->colx = 2 + rint((colorWheelSize * (1.0 + cos( cur_hsv.hue*W_PI/180))) /2.0); /* "+2" because of "colorWheelSize + 4" */ - panel->coly = 2 + rint((colorWheelSize * (1.0 + sin(-cur_hsv.hue*W_PI/180))) /2.0); + panel->colx = 2 + rint((colorWheelSize * (1.0 + cos( cur_hsv.hue*M_PI/180))) /2.0); /* "+2" because of "colorWheelSize + 4" */ + panel->coly = 2 + rint((colorWheelSize * (1.0 + sin(-cur_hsv.hue*M_PI/180))) /2.0); wheelUpdateSelection(panel); wheelUpdateBrightnessGradientFromHSV(panel, cur_hsv); @@ -2113,7 +2139,7 @@ grayBrightnessSliderCallback(WMWidget *w, void *data) WMSetTextFieldText(panel->grayBrightnessT, tmp); color.red = color.green = color.blue = rint(2.55*value); - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); panel->lastChanged = WMGrayModeColorPanel; } @@ -2141,7 +2167,7 @@ grayPresetButtonCallback(WMWidget *w, void *data) WMSetSliderValue(panel->grayBrightnessS, rint(100.0*i/6.0)); - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); panel->lastChanged = WMGrayModeColorPanel; } @@ -2164,7 +2190,7 @@ grayBrightnessTextFieldCallback(void *observerData, WMNotification *notification WMSetSliderValue(panel->grayBrightnessS, value); color.red = color.green = color.blue = rint(255.0*value/100.0); - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); panel->lastChanged = WMGrayModeColorPanel; } @@ -2194,7 +2220,7 @@ rgbSliderCallback(WMWidget *w, void *data) color.green = value[1]; color.blue = value[2]; - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); panel->lastChanged = WMRGBModeColorPanel; } @@ -2202,8 +2228,8 @@ static void rgbTextFieldCallback(void *observerData, WMNotification *notification) { RColor color; - char tmp[4]; int value[3]; + char tmp[4]; int n; W_ColorPanel *panel = (W_ColorPanel*)observerData; @@ -2233,7 +2259,7 @@ rgbTextFieldCallback(void *observerData, WMNotification *notification) color.green = value[1]; color.blue = value[2]; - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); panel->lastChanged = WMRGBModeColorPanel; } @@ -2267,7 +2293,7 @@ cmykSliderCallback(WMWidget *w, void *data) color.green = rint((255.0 - (value[1] * 2.55)) * (1.0 - (value[3] / 100.0))); color.blue = rint((255.0 - (value[2] * 2.55)) * (1.0 - (value[3] / 100.0))); - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); panel->lastChanged = WMCMYKModeColorPanel; } @@ -2275,8 +2301,8 @@ static void cmykTextFieldCallback(void *observerData, WMNotification *notification) { RColor color; - char tmp[4]; int value[4]; + char tmp[4]; int n; W_ColorPanel *panel = (W_ColorPanel*)observerData; @@ -2310,7 +2336,7 @@ cmykTextFieldCallback(void *observerData, WMNotification *notification) color.green = rint((255.0 - (value[1] * 2.55)) * (1.0 - (value[3] / 100.0))); color.blue = rint((255.0 - (value[2] * 2.55)) * (1.0 - (value[3] / 100.0))); - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); panel->lastChanged = WMCMYKModeColorPanel; } @@ -2343,7 +2369,7 @@ hsbSliderCallback(WMWidget *w, void *data) RHSVtoRGB(&panel->hsvcolor, &color); panel->lastChanged = WMHSBModeColorPanel; - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); if (w != panel->hsbBrightnessS) hsbUpdateBrightnessGradient(panel); @@ -2357,8 +2383,8 @@ static void hsbTextFieldCallback(void *observerData, WMNotification *notification) { RColor color; - char tmp[4]; int value[3]; + char tmp[4]; int n; W_ColorPanel *panel = (W_ColorPanel*)observerData; @@ -2396,7 +2422,7 @@ hsbTextFieldCallback(void *observerData, WMNotification *notification) RHSVtoRGB(&panel->hsvcolor, &color); panel->lastChanged = WMHSBModeColorPanel; - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); hsbUpdateBrightnessGradient(panel); hsbUpdateSaturationGradient(panel); @@ -2422,7 +2448,7 @@ hsbUpdateBrightnessGradient(W_ColorPanel *panel) sliderImg = RRenderGradient(141, 16, &from, &to, RGRD_HORIZONTAL); sliderPxmp = WMCreatePixmapFromRImage(scr, sliderImg, 0); RDestroyImage(sliderImg); - W_PaintText(W_VIEW(panel->hsbBrightnessS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scr->white), False, "Brightness", strlen("Brightness")); + W_PaintText(W_VIEW(panel->hsbBrightnessS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scr->white), False, "Brightness", strlen("Brightness")); WMSetSliderImage(panel->hsbBrightnessS, sliderPxmp); WMReleasePixmap(sliderPxmp); } @@ -2448,9 +2474,9 @@ hsbUpdateSaturationGradient(W_ColorPanel *panel) sliderPxmp = WMCreatePixmapFromRImage(scr, sliderImg, 0); RDestroyImage(sliderImg); if (hsvcolor.value < 128) - W_PaintText(W_VIEW(panel->hsbSaturationS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scr->white), False, "Saturation", strlen("Saturation")); + W_PaintText(W_VIEW(panel->hsbSaturationS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scr->white), False, "Saturation", strlen("Saturation")); else - W_PaintText(W_VIEW(panel->hsbSaturationS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scr->black), False, "Saturation", strlen("Saturation")); + W_PaintText(W_VIEW(panel->hsbSaturationS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scr->black), False, "Saturation", strlen("Saturation")); WMSetSliderImage(panel->hsbSaturationS, sliderPxmp); WMReleasePixmap(sliderPxmp); @@ -2480,9 +2506,9 @@ hsbUpdateHueGradient(W_ColorPanel *panel) sliderPxmp = WMCreatePixmapFromRImage(scr, sliderImg, 0); RDestroyImage(sliderImg); if (hsvcolor.value < 128) - W_PaintText(W_VIEW(panel->hsbHueS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scr->white), False, "Hue", strlen("Hue")); + W_PaintText(W_VIEW(panel->hsbHueS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scr->white), False, "Hue", strlen("Hue")); else - W_PaintText(W_VIEW(panel->hsbHueS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, W_GC(scr->black), False, "Hue", strlen("Hue")); + W_PaintText(W_VIEW(panel->hsbHueS), sliderPxmp->pixmap, panel->font12, 2, 0, 100, WALeft, WMColorGC(scr->black), False, "Hue", strlen("Hue")); WMSetSliderImage(panel->hsbHueS, sliderPxmp); WMReleasePixmap(sliderPxmp); @@ -2578,8 +2604,8 @@ customSetPalette(W_ColorPanel *panel) item = WMGetPopUpButtonSelectedItem (panel->customPaletteHistoryBtn); /* if palette != "Spectrum", we are allowed to rename and remove it */ - WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, menuRename, (item > 0) ); - WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, menuRemove, (item > 0) ); + WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, CPmenuRename, (item > 0) ); + WMSetPopUpButtonItemEnabled(panel->customPaletteMenuBtn, CPmenuRemove, (item > 0) ); } @@ -2602,7 +2628,7 @@ customPalettePositionSelection(W_ColorPanel *panel, int x, int y) panel->color.green = panel->customPaletteImg->data[1][ofs]; panel->color.blue = panel->customPaletteImg->data[2][ofs]; - WMSetColorPanelColor(panel, panel->color); + updateSwatch(panel, panel->color); panel->lastChanged = WMCustomPaletteModeColorPanel; /* Redraw color selector (and make a backup of the part it will cover) */ @@ -2660,6 +2686,10 @@ customPaletteHandleActionEvents(XEvent *event, void *data) case ButtonRelease: panel->flags.dragging = 0; + if (!panel->flags.continuous) { + if (panel->action) + (*panel->action)(panel->action, panel->clientData); + } break; case MotionNotify: @@ -2682,23 +2712,21 @@ static void customPaletteMenuCallback(WMWidget *w, void *data) { W_ColorPanel *panel = (W_ColorPanel*)data; - int item; - - item = WMGetPopUpButtonSelectedItem(panel->customPaletteMenuBtn); + int item = WMGetPopUpButtonSelectedItem(panel->customPaletteMenuBtn); switch (item) { - case menuNewFromFile: + case CPmenuNewFromFile: customPaletteMenuNewFromFile(panel); break; - case menuRename: + case CPmenuRename: customPaletteMenuRename(panel); break; - case menuRemove: + case CPmenuRemove: customPaletteMenuRemove(panel); break; - case menuCopy: + case CPmenuCopy: break; - case menuNewFromClipboard: + case CPmenuNewFromClipboard: break; } } @@ -2726,16 +2754,16 @@ customPaletteMenuNewFromFile(W_ColorPanel *panel) WMSetFilePanelCanChooseFiles(browseP, 1); /* Get a filename */ - if (WMRunModalFilePanelForDirectory(browseP, panel->win, spath, - "Open Palette", - RSupportedFileFormats())) { + if (WMRunModalFilePanelForDirectory(browseP, panel->win, spath, + "Open Palette", + RSupportedFileFormats()) ) { filepath = WMGetFilePanelFileName(browseP); - + /* Get seperation position between path and filename */ i = strrchr(filepath, '/') - filepath + 1; if (i > strlen(filepath)) i = strlen(filepath); - + /* Store last browsed path */ if (panel->lastBrowseDir) free(panel->lastBrowseDir); @@ -2748,21 +2776,21 @@ customPaletteMenuNewFromFile(W_ColorPanel *panel) /* Check for duplicate files, and rename it if there are any */ tmp = wstrappend(panel->configurationPath, filename); - while (access(tmp, F_OK) == 0) { - char *newName; - + while (access (tmp, F_OK) == 0) { + char *newName; + free(tmp); - + newName = generateNewFilename(filename); - free(filename); - filename = newName; - + free(filename); + filename = newName; + tmp = wstrappend(panel->configurationPath, filename); } free(tmp); /* Copy the image to $(gnustepdir)/Library/Colors/ & Add the filename to the history menu */ - if (!fetchImageFile (panel->configurationPath, filepath, filename)) { /* error = -1 */ + if (fetchFile (panel->configurationPath, filepath, filename) == 0) { /* filepath is a "local" path now the file has been copied */ free(filepath); @@ -2778,29 +2806,29 @@ customPaletteMenuNewFromFile(W_ColorPanel *panel) customSetPalette(panel); WMAddPopUpButtonItem(panel->customPaletteHistoryBtn, filename); - panel->currentPalette = - WMGetPopUpButtonNumberOfItems(panel->customPaletteHistoryBtn)-1; + panel->currentPalette = WMGetPopUpButtonNumberOfItems(panel->customPaletteHistoryBtn)-1; - WMSetPopUpButtonSelectedItem(panel->customPaletteHistoryBtn, + WMSetPopUpButtonSelectedItem(panel->customPaletteHistoryBtn, panel->currentPalette); } - } else { + } + else + { tmp = wstrappend(panel->configurationPath, filename); - i = remove(tmp); /* Delete the file, it doesn't belong here */ + i = remove(tmp); /* Delete the file, it doesn't belong here */ WMRunAlertPanel(scr, panel->win, "File Error", "Invalid file format !", "OK", NULL, NULL); if (i != 0) { - wsyserror("can't remove file %s", tmp); + wsyserror("can't remove file %s", tmp); WMRunAlertPanel(scr, panel->win, "File Error", "Couldn't remove file from Configuration Directory !", "OK", NULL, NULL); - } - + } free(tmp); } free(filepath); - free(filename); + free(filename); } WMFreeFilePanel(browseP); - + free(spath); } @@ -2958,7 +2986,6 @@ static void wheelInit(W_ColorPanel *panel) { RHSVColor cur_hsv; - float W_PI = 4 * atan(1); int i; int v; @@ -2967,8 +2994,8 @@ wheelInit(W_ColorPanel *panel) WMSetSliderValue(panel->wheelBrightnessS, 255-cur_hsv.value); wheelUpdateBrightnessGradientFromHSV(panel, cur_hsv); - panel->colx = 2 + rint((colorWheelSize / 2.0) * (1 + (cur_hsv.saturation/255.0) * cos( cur_hsv.hue*W_PI/180.0))); - panel->coly = 2 + rint((colorWheelSize / 2.0) * (1 + (cur_hsv.saturation/255.0) * sin(-cur_hsv.hue*W_PI/180.0))); + panel->colx = 2 + rint((colorWheelSize / 2.0) * (1 + (cur_hsv.saturation/255.0) * cos( cur_hsv.hue*M_PI/180.0))); + panel->coly = 2 + rint((colorWheelSize / 2.0) * (1 + (cur_hsv.saturation/255.0) * sin(-cur_hsv.hue*M_PI/180.0))); for (i = 0; i < 256; i++) { /* We divide by 128 in advance, and check whether that number divides @@ -3074,12 +3101,10 @@ colorListPaintItem(WMList *lPtr, int index, Drawable d, char *text, int state, W RColor color = *((RColor *)WMGetListItem(lPtr, index)->clientData); WMScreen *scr = WMWidgetScreen(lPtr); Display *dpy = WMScreenDisplay(scr); - RImage *image; - WMPixmap *pixmap; - int i, j; W_ColorPanel *panel = WMGetHangedData(lPtr); WMColor *white = WMWhiteColor(scr); WMColor *black = WMBlackColor(scr); + WMColor *fillColor; width = rect->size.width; height = rect->size.height; @@ -3087,26 +3112,18 @@ colorListPaintItem(WMList *lPtr, int index, Drawable d, char *text, int state, W y = rect->pos.y; if (state & WLDSSelected) - XFillRectangle(dpy, d, WMColorGC(white), x, y, width, height); + WMPaintColorSwatch(white, d, x +15, y, width -15, height); else - XClearArea(dpy, d, x, y, width, height, False); - - image = RCreateImage(15, 15, False); - for (i=0; i < 15 ; i++) { - for (j=0; j < 15; j++) { - image->data[0][j*15+i] = color.red; - image->data[1][j*15+i] = color.green; - image->data[2][j*15+i] = color.blue; - } - } + XClearArea(dpy, d, x +15, y, width -15, height, False); + + fillColor = WMCreateRGBColor(scr, color.red*256, color.green*256, color.blue*256, False); + + WMSetColorInGC(fillColor, WMColorGC(fillColor)); + WMPaintColorSwatch(fillColor, d, x, y, 15, 15); + WMReleaseColor(fillColor); + + WMDrawString(scr, d, WMColorGC(black), panel->font12, x+18, y, text, strlen(text)); - pixmap = WMCreatePixmapFromRImage(scr, image, 0); - RDestroyImage(image); - WMDrawPixmap(pixmap, d, x, y); - WMReleasePixmap(pixmap); - WMDrawString(scr, d, WMColorGC(black), panel->font12, x+18, y, text, - strlen(text)); - WMReleaseColor(white); WMReleaseColor(black); } @@ -3116,32 +3133,73 @@ static void colorListSelect(WMWidget *w, void *data) { W_ColorPanel *panel = (W_ColorPanel *)data; - RColor color = *((RColor *)WMGetListSelectedItem(w)->clientData); + RColor color = *((RColor *)WMGetListSelectedItem(w)->clientData); panel->lastChanged = WMColorListModeColorPanel; - WMSetColorPanelColor(panel, color); + updateSwatch(panel, color); } +static void +colorListColorMenuCallback(WMWidget *w, void *data) +{ + W_ColorPanel *panel = (W_ColorPanel *)data; + int item = WMGetPopUpButtonSelectedItem(panel->colorListColorMenuBtn); + + switch (item) { + case CLmenuAdd: + break; + case CLmenuRename: + break; + case CLmenuRemove: + break; + } +} + + +static void +colorListListMenuCallback(WMWidget *w, void *data) +{ + W_ColorPanel *panel = (W_ColorPanel *)data; + int item = WMGetPopUpButtonSelectedItem(panel->colorListListMenuBtn); + + switch (item) { + case CLmenuAdd: + /* New Color List */ + colorListListMenuNew(panel); + break; + case CLmenuRename: + break; + case CLmenuRemove: + break; + } +} + + +static void +colorListListMenuNew(W_ColorPanel *panel) +{ + +} /************************** Common utility functions ************************/ static int -fetchImageFile(char *toPath, char *imageSrcFile, char *imageDestFile) +fetchFile(char *toPath, char *srcFile, char *destFile) { int src, dest; int n; char *tmp; char buf[BUFSIZE]; - if ((src = open(imageSrcFile, O_RDONLY)) < 0) { - wsyserror("Could not open %s", imageSrcFile); + if ((src = open(srcFile, O_RDONLY)) == 0) { + wsyserror("Could not open %s", srcFile); return -1; } - tmp = wstrappend(toPath, imageDestFile); - if ((dest = open( tmp, O_RDWR|O_CREAT, S_IRWXU|S_IRGRP|S_IROTH)) < 0) { + tmp = wstrappend(toPath, destFile); + if ((dest = open( tmp, O_RDWR|O_CREAT, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH)) == 0) { wsyserror("Could not create %s", tmp); free(tmp); return -1; @@ -3152,117 +3210,40 @@ fetchImageFile(char *toPath, char *imageSrcFile, char *imageDestFile) /* Copy the file */ while ((n = read(src, buf, BUFSIZE)) > 0) { - if (write(dest, buf, n) != n) { - wsyserror("Write error on file %s", imageDestFile); + if (write (dest, buf, n) != n) { + wsyserror("Write error on file %s", destFile); return -1; } } - + return 0; } - char* generateNewFilename(char *curName) { -#if 1 - int n; - int baseLen; - char *ptr; - char *newName; - - ptr = strrchr(curName, '{'); - if (!ptr || sscanf(ptr, "{%i}", &n)!=1) { - return wstrappend(curName, " {1}"); - } - - baseLen = ptr - curName; - - newName = wmalloc(baseLen + 16); - strncpy(newName, curName, baseLen); - newName[baseLen] = 0; - - sprintf(&newName[baseLen], " {%i}", n+1); - - return newName; -#else + int n; + char c; + int baseLen; + char *ptr; char *newName; - char *numStart, *numEnd; - char *pre, *num, *post; - int n, numLength; - char *tmp; - - newName = wstrdup(curName); - - if (newName == NULL) - return wstrdup("Unnamed"); - /* - * Modify the name to contain a number to make it unique - */ + ptr = curName; - /* Get number-string from filename. */ - numStart = strrchr(newName, '-'); - if (numStart) { - if (strlen(numStart) > 1) - numStart++; /* Next character, please */ - - - numEnd = strrchr(numStart, '-'); /* Already past "numbers" */ - - if (numEnd) { - /* Now it gets interesting */ - - pre = wmalloc((numStart - newName +1) * sizeof(char)); /* a trailing '\0' is useful here */ - strncpy (pre, newName, numStart-newName); - pre[numStart - newName] = '\0'; - - num = wmalloc((numEnd - numStart +1) * sizeof(char)); - strncpy (num, numStart, numEnd-numStart); - num[numEnd - numStart] = '\0'; - - post = wstrdup( numEnd); - - free(newName); /* We don't need it anymore */ - - if (strcspn(num, "0123456789") == 0) { - n = (int)strtol(num, NULL, 10); - - /* Increase number between brackets (in filename); This is what it all is about */ - n++; - - free(num); - num = wmalloc(3 * sizeof(char)); /* Nobody uses more than 999 duplicate filenames, do you ? */ - numLength = sprintf(num, "%d", n); - - free(num); - num = wmalloc(numLength * sizeof(char)); - sprintf(num, "%d", n); - - tmp = wstrappend (num, post); - newName = wstrappend (pre, tmp); - - free(pre); - free(num); - free(post); - free(tmp); - } - } + while ((ptr = strrchr(ptr, '{')) && !(sscanf(ptr, "{%i}%c", &n, &c)==1)) { + ptr++; } + if (!ptr) + return wstrappend(curName, " {1}"); - if (strcmp( curName, newName) == 0) { - /* The name is still unchanged, so there was no number (between brackets) in it. - Add a number 1 to the end. - */ - tmp = wstrdup(newName); - if (newName) - free(newName); - newName = wstrappend(tmp, " -1-"); - free(tmp); - } + baseLen = ptr - curName -1; + + newName = wmalloc(baseLen + 16); + strncpy(newName, curName, baseLen); + newName[baseLen] = 0; + + sprintf(&newName[baseLen], " {%i}", n+1); return newName; -#endif } - diff --git a/WINGs/wcolorwell.c b/WINGs/wcolorwell.c index 728f29ea..bbe3cd8f 100644 --- a/WINGs/wcolorwell.c +++ b/WINGs/wcolorwell.c @@ -24,6 +24,9 @@ typedef struct W_ColorWell { } flags; } ColorWell; +static char *_ColorWellActivatedNotification = "_ColorWellActivatedNotification"; + + static void destroyColorWell(ColorWell *cPtr); static void paintColorWell(ColorWell *cPtr); @@ -36,6 +39,8 @@ static void handleActionEvents(XEvent *event, void *data); static void resizeColorWell(); + + W_ViewProcedureTable _ColorWellViewProcedures = { NULL, resizeColorWell, @@ -58,6 +63,21 @@ static WMDragSourceProcs dragProcs = { +static void +activatedObserver(void *data, WMNotification *notification) +{ + WMColorWell *cPtr = (WMColorWell*)data; + + if (!cPtr->flags.active || WMGetNotificationObject(notification) == cPtr) + return; + + W_SetViewBackgroundColor(cPtr->view, WMWidgetScreen(cPtr)->gray); + paintColorWell(cPtr); + + cPtr->flags.active = 0; +} + + WMColorWell* WMCreateColorWell(WMWidget *parent) { @@ -97,9 +117,14 @@ WMCreateColorWell(WMWidget *parent) cPtr->colorView->flags.mapWhenRealized = 1; cPtr->flags.bordered = 1; - + resizeColorWell(cPtr, DEFAULT_WIDTH, DEFAULT_HEIGHT); + WMAddNotificationObserver(activatedObserver, cPtr, + _ColorWellActivatedNotification, NULL); + + cPtr->color = WMBlackColor(WMWidgetScreen(cPtr)); + return cPtr; } @@ -379,14 +404,54 @@ handleDragEvents(XEvent *event, void *data) static void handleActionEvents(XEvent *event, void *data) { -/* WMColorWell *cPtr = (ColorWell*)data;*/ + WMColorWell *cPtr = (ColorWell*)data; + WMScreen *scr = WMWidgetScreen(cPtr); + WMColorPanel *cpanel; + if (cPtr->flags.active) + W_SetViewBackgroundColor(cPtr->view, scr->gray); + else + W_SetViewBackgroundColor(cPtr->view, scr->white); + paintColorWell(cPtr); + + cPtr->flags.active ^= 1; + + if (cPtr->flags.active) { + WMPostNotificationName(_ColorWellActivatedNotification, cPtr, NULL); + } +/* + cpanel = WMGetColorPanel(scr); + if (cPtr->color) + WMSetColorPanelColor(cpanel, cPtr->color); + WMShowColorPanel(cpanel); + * + */ + { + char *t; + WMColor *color; + + t = WMRunInputPanel(scr, NULL, "Advanced Color Picker", + "Type a Color (this is temporary!!! I'm not THAT dumb :P)", + NULL, "OK", "Cancel"); + + if (t) { + color = WMCreateNamedColor(scr, t, False); + if (color) { + WMSetColorWellColor(cPtr, color); + WMReleaseColor(color); + } + free(t); + } + + } } static void destroyColorWell(ColorWell *cPtr) { + WMRemoveNotificationObserver(cPtr); + if (cPtr->color) WMReleaseColor(cPtr->color); diff --git a/WINGs/wfilepanel.c b/WINGs/wfilepanel.c index 02a106d0..6cc4fbc3 100644 --- a/WINGs/wfilepanel.c +++ b/WINGs/wfilepanel.c @@ -104,16 +104,22 @@ textChangedObserver(void *observerData, WMNotification *notification) char *text; WMList *list; int col = WMGetBrowserNumberOfColumns(panel->browser) - 1; - int i, j, textEvent; + int i, textEvent = (int)WMGetNotificationClientData(notification); + static int running = 0; + + if (running) + return; + + running = 1; if (panel->flags.ignoreTextChangeNotification) return; - if (!(list = WMGetBrowserListInColumn(panel->browser, col))) - return; + list = WMGetBrowserListInColumn(panel->browser, col); + if (!list) + return; text = WMGetTextFieldText(panel->fileField); - textEvent = (int)WMGetNotificationClientData(notification); if (panel->flags.autoCompletion && textEvent!=WMDeleteTextEvent) i = closestListItem(list, text, False); @@ -126,16 +132,14 @@ textChangedObserver(void *observerData, WMNotification *notification) int textLen = strlen(text), itemTextLen = strlen(item->text); int visibleItems = WMWidgetHeight(list)/WMGetListItemHeight(list); - WMSetListPosition(list, i - visibleItems/2); + if (textEvent!=WMSetTextEvent || textLenflags.ignoreTextChangeNotification = 1; + WMInsertTextFieldText(panel->fileField, &item->text[textLen], - textLen); - panel->flags.ignoreTextChangeNotification = 0; - + textLen); WMSetTextFieldCursorPosition(panel->fileField, itemTextLen); range.position = textLen; range.count = itemTextLen - textLen; @@ -144,6 +148,7 @@ textChangedObserver(void *observerData, WMNotification *notification) } free(text); + running = 0; } @@ -317,12 +322,12 @@ WMRunModalFilePanelForDirectory(WMFilePanel *panel, WMWindow *owner, WMScreen *scr = WMWidgetScreen(panel->win); XEvent event; - WMChangePanelOwner(panel->win, owner); - if (name && !owner) { WMSetWindowTitle(panel->win, name); } + WMChangePanelOwner(panel->win, owner); + WMSetFilePanelDirectory(panel, path); panel->flags.done = 0; @@ -346,12 +351,19 @@ WMRunModalFilePanelForDirectory(WMFilePanel *panel, WMWindow *owner, WMSetLabelText(panel->titleLabel, name); + scr->modalView = W_VIEW(panel->win); WMMapWidget(panel->win); + WMMoveWidget(panel->win, + (scr->rootView->size.width - WMWidgetWidth(panel->win))/2, + (scr->rootView->size.height - WMWidgetHeight(panel->win))/2); + + scr->modal = 1; while (!panel->flags.done) { WMNextEvent(scr->display, &event); WMHandleEvent(&event); } + scr->modal = 0; /* Must withdraw window because the next time we map * it, it might have a different transient owner. diff --git a/WINGs/wfont.c b/WINGs/wfont.c index 91c9feb7..6084f499 100644 --- a/WINGs/wfont.c +++ b/WINGs/wfont.c @@ -18,9 +18,16 @@ WMCreateFont(WMScreen *scrPtr, char *fontName) char *defaultString; XFontSetExtents *extents; + font = WMHashGet(scrPtr->fontCache, fontName); + if (font) { + WMRetainFont(font); + return font; + } + font = malloc(sizeof(WMFont)); if (!font) return NULL; + memset(font, 0, sizeof(WMFont)); font->notFontSet = 0; @@ -50,9 +57,13 @@ WMCreateFont(WMScreen *scrPtr, char *fontName) font->height = extents->max_logical_extent.height; font->y = font->height - (font->height + extents->max_logical_extent.y); - + font->refCount = 1; - + + font->name = wstrdup(fontName); + + assert(WMHashInsert(scrPtr->fontCache, font->name, font)==NULL); + return font; } @@ -66,12 +77,13 @@ WMCreateFontInDefaultEncoding(WMScreen *scrPtr, char *fontName) font = malloc(sizeof(WMFont)); if (!font) - return NULL; + return NULL; + memset(font, 0, sizeof(WMFont)); font->notFontSet = 1; font->screen = scrPtr; - + font->font.normal = XLoadQueryFont(display, fontName); if (!font->font.normal) { free(font); @@ -108,8 +120,13 @@ WMReleaseFont(WMFont *font) if (font->refCount < 1) { if (font->notFontSet) XFreeFont(font->screen->display, font->font.normal); - else + else { XFreeFontSet(font->screen->display, font->font.set); + } + if (font->name) { + WMHashRemove(font->screen->fontCache, font->name); + free(font->name); + } free(font); } } diff --git a/WINGs/wframe.c b/WINGs/wframe.c index 0fa2e028..1811c87c 100644 --- a/WINGs/wframe.c +++ b/WINGs/wframe.c @@ -149,10 +149,10 @@ paintFrame(Frame *fPtr) tx = (view->size.width - tw) / 2; - XFillRectangle(scrPtr->display, view->window, W_GC(scrPtr->gray), + XFillRectangle(scrPtr->display, view->window, WMColorGC(scrPtr->gray), tx, ty, tw, th); - WMDrawString(scrPtr, view->window, W_GC(scrPtr->black), + WMDrawString(scrPtr, view->window, WMColorGC(scrPtr->black), scrPtr->normalFont, tx, ty, fPtr->caption, strlen(fPtr->caption)); } diff --git a/WINGs/widgets.c b/WINGs/widgets.c index b0f409d8..13c84745 100644 --- a/WINGs/widgets.c +++ b/WINGs/widgets.c @@ -358,10 +358,10 @@ renderPixmap(W_Screen *screen, Pixmap d, Pixmap mask, char **data, int width, int height) { int x, y; - GC whiteGC = W_GC(screen->white); - GC blackGC = W_GC(screen->black); - GC lightGC = W_GC(screen->gray); - GC darkGC = W_GC(screen->darkGray); + GC whiteGC = WMColorGC(screen->white); + GC blackGC = WMColorGC(screen->black); + GC lightGC = WMColorGC(screen->gray); + GC darkGC = WMColorGC(screen->darkGray); if (mask) @@ -583,6 +583,7 @@ WMCreateScreenWithRContext(Display *display, int screen, RContext *context) scrPtr->rootWin = RootWindow(display, screen); + scrPtr->fontCache = WMCreateHashTable(WMStringPointerHashCallbacks); /* initially allocate some colors */ WMWhiteColor(scrPtr); diff --git a/WINGs/wlabel.c b/WINGs/wlabel.c index c99b65f9..609ed7c9 100644 --- a/WINGs/wlabel.c +++ b/WINGs/wlabel.c @@ -196,9 +196,9 @@ paintLabel(Label *lPtr) GC gc; if (lPtr->textColor) - gc = W_GC(lPtr->textColor); + gc = WMColorGC(lPtr->textColor); else - gc = W_GC(scrPtr->black); + gc = WMColorGC(scrPtr->black); W_PaintTextAndImage(lPtr->view, !lPtr->flags.noWrap, gc, (lPtr->font!=NULL ? lPtr->font : scrPtr->normalFont), diff --git a/WINGs/wlist.c b/WINGs/wlist.c index c9a02573..19bc6b2b 100644 --- a/WINGs/wlist.c +++ b/WINGs/wlist.c @@ -546,13 +546,13 @@ paintItem(List *lPtr, int index) &rect); } else { if (itemPtr->selected) - XFillRectangle(scr->display, view->window, W_GC(scr->white), x, y, + XFillRectangle(scr->display, view->window, WMColorGC(scr->white), x, y, width, height); else XClearArea(scr->display, view->window, x, y, width, height, False); W_PaintText(view, view->window, scr->normalFont, x+4, y, width, - WALeft, W_GC(scr->black), False, + WALeft, WMColorGC(scr->black), False, itemPtr->text, strlen(itemPtr->text)); } } diff --git a/WINGs/wmisc.c b/WINGs/wmisc.c index e6f9f0ab..7cdbaca1 100644 --- a/WINGs/wmisc.c +++ b/WINGs/wmisc.c @@ -17,37 +17,37 @@ W_DrawRelief(W_Screen *scr, Drawable d, int x, int y, unsigned int width, switch (relief) { case WRSimple: - XDrawRectangle(dpy, d, W_GC(scr->black), x, y, width-1, height-1); + XDrawRectangle(dpy, d, WMColorGC(scr->black), x, y, width-1, height-1); return; break; case WRRaised: - bgc = W_GC(scr->black); - dgc = W_GC(scr->darkGray); - wgc = W_GC(scr->white); - lgc = W_GC(scr->gray); + bgc = WMColorGC(scr->black); + dgc = WMColorGC(scr->darkGray); + wgc = WMColorGC(scr->white); + lgc = WMColorGC(scr->gray); break; case WRSunken: - wgc = W_GC(scr->darkGray); - lgc = W_GC(scr->black); - bgc = W_GC(scr->white); - dgc = W_GC(scr->gray); + wgc = WMColorGC(scr->darkGray); + lgc = WMColorGC(scr->black); + bgc = WMColorGC(scr->white); + dgc = WMColorGC(scr->gray); break; case WRPushed: - lgc = wgc = W_GC(scr->black); - dgc = bgc = W_GC(scr->white); + lgc = wgc = WMColorGC(scr->black); + dgc = bgc = WMColorGC(scr->white); break; case WRRidge: - lgc = bgc = W_GC(scr->darkGray); - dgc = wgc = W_GC(scr->white); + lgc = bgc = WMColorGC(scr->darkGray); + dgc = wgc = WMColorGC(scr->white); break; case WRGroove: - wgc = dgc = W_GC(scr->darkGray); - lgc = bgc = W_GC(scr->white); + wgc = dgc = WMColorGC(scr->darkGray); + lgc = bgc = WMColorGC(scr->white); break; default: diff --git a/WINGs/wpixmap.c b/WINGs/wpixmap.c index 43a5f84f..49b99bb5 100644 --- a/WINGs/wpixmap.c +++ b/WINGs/wpixmap.c @@ -31,6 +31,34 @@ WMReleasePixmap(WMPixmap *pixmap) WMPixmap* +WMCreatePixmap(WMScreen *scrPtr, int width, int height, int depth, Bool masked) +{ + WMPixmap *pixPtr; + + pixPtr = malloc(sizeof(WMPixmap)); + if (!pixPtr) { + return NULL; + } + pixPtr->screen = scrPtr; + pixPtr->width = width; + pixPtr->height = height; + pixPtr->depth = depth; + pixPtr->refCount = 1; + + pixPtr->pixmap = XCreatePixmap(scrPtr->display, W_DRAWABLE(scrPtr), + width, height, depth); + if (masked) { + pixPtr->mask = XCreatePixmap(scrPtr->display, W_DRAWABLE(scrPtr), + width, height, 1); + } else { + pixPtr->mask = None; + } + + return pixPtr; +} + + +WMPixmap* WMCreatePixmapFromXPixmaps(WMScreen *scrPtr, Pixmap pixmap, Pixmap mask, int width, int height, int depth) { diff --git a/WINGs/wpopupbutton.c b/WINGs/wpopupbutton.c index 52058e65..e29aceb9 100644 --- a/WINGs/wpopupbutton.c +++ b/WINGs/wpopupbutton.c @@ -403,7 +403,7 @@ paintPopUpButton(PopUpButton *bPtr) pixmap = XCreatePixmap(scr->display, bPtr->view->window, bPtr->view->size.width, bPtr->view->size.height, scr->depth); - XFillRectangle(scr->display, pixmap, W_GC(scr->gray), 0, 0, + XFillRectangle(scr->display, pixmap, WMColorGC(scr->gray), 0, 0, bPtr->view->size.width, bPtr->view->size.height); W_DrawRelief(scr, pixmap, 0, 0, bPtr->view->size.width, @@ -413,7 +413,7 @@ paintPopUpButton(PopUpButton *bPtr) W_PaintText(bPtr->view, pixmap, scr->normalFont, 6, (bPtr->view->size.height-WMFontHeight(scr->normalFont))/2, bPtr->view->size.width, WALeft, - bPtr->flags.enabled ? W_GC(scr->black) : W_GC(scr->darkGray), + bPtr->flags.enabled ? WMColorGC(scr->black) : WMColorGC(scr->darkGray), False, caption, strlen(caption)); } @@ -489,7 +489,7 @@ paintMenuEntry(PopUpButton *bPtr, int index, int highlight) return; } - XFillRectangle(scr->display, bPtr->menuView->window, W_GC(scr->white), + XFillRectangle(scr->display, bPtr->menuView->window, WMColorGC(scr->white), 1, index*itemHeight+1, width-3, itemHeight-3); itemPtr = bPtr->items; @@ -500,7 +500,7 @@ paintMenuEntry(PopUpButton *bPtr, int index, int highlight) width, itemHeight, WRRaised); W_PaintText(bPtr->menuView, bPtr->menuView->window, scr->normalFont, 6, - index*itemHeight + yo, width, WALeft, W_GC(scr->black), False, + index*itemHeight + yo, width, WALeft, WMColorGC(scr->black), False, itemPtr->text, strlen(itemPtr->text)); if (!bPtr->flags.pullsDown && index == bPtr->selectedItemIndex) { @@ -531,7 +531,7 @@ makeMenuPixmap(PopUpButton *bPtr) pixmap = XCreatePixmap(scr->display, bPtr->view->window, width, height, scr->depth); - XFillRectangle(scr->display, pixmap, W_GC(scr->gray), 0, 0, width, height); + XFillRectangle(scr->display, pixmap, WMColorGC(scr->gray), 0, 0, width, height); itemPtr = bPtr->items; for (i = 0; i < bPtr->itemCount; i++) { @@ -541,9 +541,9 @@ makeMenuPixmap(PopUpButton *bPtr) WRRaised); if (itemPtr->disabled) - gc = W_GC(scr->darkGray); + gc = WMColorGC(scr->darkGray); else - gc = W_GC(scr->black); + gc = WMColorGC(scr->black); W_PaintText(bPtr->menuView, pixmap, scr->normalFont, 6, i*itemHeight + yo, width, WALeft, gc, False, @@ -569,7 +569,8 @@ resizeMenu(PopUpButton *bPtr) int height; height = bPtr->itemCount * bPtr->view->size.height; - W_ResizeView(bPtr->menuView, bPtr->view->size.width, height); + if (height > 0) + W_ResizeView(bPtr->menuView, bPtr->view->size.width, height); } diff --git a/WINGs/wscroller.c b/WINGs/wscroller.c index 5d395c23..df110f43 100644 --- a/WINGs/wscroller.c +++ b/WINGs/wscroller.c @@ -260,7 +260,7 @@ paintArrow(WMScroller *sPtr, Drawable d, int part) #ifndef DOUBLE_BUFFER if (sPtr->flags.decrDown) - gc = W_GC(scr->white); + gc = WMColorGC(scr->white); #endif } else { /* increment button */ if (sPtr->flags.horizontal) { @@ -300,7 +300,7 @@ paintArrow(WMScroller *sPtr, Drawable d, int part) ofs+1, 2+1, bsize+1-3, bsize-3); #else if ((!part&&sPtr->flags.decrDown) || (part&&sPtr->flags.incrDown)) - XFillRectangle(scr->display, d, W_GC(scr->white), + XFillRectangle(scr->display, d, WMColorGC(scr->white), ofs+1, 2+1, bsize+1-3, bsize-3); #endif /* DOUBLE_BUFFER */ W_DrawRelief(scr, d, ofs, 2, bsize, bsize, WRRaised); @@ -324,7 +324,7 @@ paintArrow(WMScroller *sPtr, Drawable d, int part) 2+1, ofs+1, bsize-3, bsize+1-3); #else if ((!part&&sPtr->flags.decrDown) || (part&&sPtr->flags.incrDown)) - XFillRectangle(scr->display, d, W_GC(scr->white), + XFillRectangle(scr->display, d, WMColorGC(scr->white), 2+1, ofs+1, bsize-3, bsize+1-3); #endif /* DOUBLE_BUFFER */ W_DrawRelief(scr, d, 2, ofs, bsize, bsize, WRRaised); @@ -386,14 +386,14 @@ paintScroller(Scroller *sPtr) #ifdef DOUBLE_BUFFER d = XCreatePixmap(scr->display, view->window, view->size.width, view->size.height, scr->depth); - XFillRectangle(scr->display, d, W_GC(scr->gray), 0, 0, + XFillRectangle(scr->display, d, WMColorGC(scr->gray), 0, 0, view->size.width, view->size.height); #endif - XDrawRectangle(scr->display, d, W_GC(scr->black), 0, 0, + XDrawRectangle(scr->display, d, WMColorGC(scr->black), 0, 0, view->size.width-1, view->size.height-1); #ifndef DOUBLE_BUFFER - XDrawRectangle(scr->display, d, W_GC(scr->gray), 1, 1, + XDrawRectangle(scr->display, d, WMColorGC(scr->gray), 1, 1, view->size.width-3, view->size.height-3); #endif diff --git a/WINGs/wslider.c b/WINGs/wslider.c index d73b693a..63af73b4 100644 --- a/WINGs/wslider.c +++ b/WINGs/wslider.c @@ -245,43 +245,43 @@ makeKnobPixmap(Slider *sPtr) } pix = XCreatePixmap(scr->display, sPtr->view->window, w, h, scr->depth); - XFillRectangle(scr->display, pix, W_GC(scr->gray), 0, 0, w, h); + XFillRectangle(scr->display, pix, WMColorGC(scr->gray), 0, 0, w, h); if (sPtr->knobThickness < 10) { W_DrawRelief(scr, pix, 0, 0, w, h, WRRaised); } else if (sPtr->flags.vertical) { - XDrawLine(scr->display, pix, W_GC(scr->white), 0, 0, 0, h-3); - XDrawLine(scr->display, pix, W_GC(scr->white), 1, 0, 1, h-3); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), w-2, 1, w-2, h/2-2); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), w-2, h/2, w-2, h-2); + XDrawLine(scr->display, pix, WMColorGC(scr->white), 0, 0, 0, h-3); + XDrawLine(scr->display, pix, WMColorGC(scr->white), 1, 0, 1, h-3); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), w-2, 1, w-2, h/2-2); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), w-2, h/2, w-2, h-2); - XDrawLine(scr->display, pix, W_GC(scr->white), 0, 0, w-2, 0); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), 1, h/2-2, w-3, h/2-2); - XDrawLine(scr->display, pix, W_GC(scr->white), 0, h/2-1, w-3, h/2-1); + XDrawLine(scr->display, pix, WMColorGC(scr->white), 0, 0, w-2, 0); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), 1, h/2-2, w-3, h/2-2); + XDrawLine(scr->display, pix, WMColorGC(scr->white), 0, h/2-1, w-3, h/2-1); - XDrawLine(scr->display, pix, W_GC(scr->black), w-1, 0, w-1, h-2); + XDrawLine(scr->display, pix, WMColorGC(scr->black), w-1, 0, w-1, h-2); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), 0, h-3, w-2, h-3); - XDrawLine(scr->display, pix, W_GC(scr->black), 0, h-2, w-1, h-2); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), 0, h-1, w-1,h-1); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), 0, h-3, w-2, h-3); + XDrawLine(scr->display, pix, WMColorGC(scr->black), 0, h-2, w-1, h-2); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), 0, h-1, w-1,h-1); } else { - XDrawLine(scr->display, pix, W_GC(scr->white), 0, 0, w-3, 0); + XDrawLine(scr->display, pix, WMColorGC(scr->white), 0, 0, w-3, 0); - XDrawLine(scr->display, pix, W_GC(scr->white), 0, 0, 0, h-2); + XDrawLine(scr->display, pix, WMColorGC(scr->white), 0, 0, 0, h-2); - XDrawLine(scr->display, pix, W_GC(scr->white), 1, 0, 1, h-3); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), w/2-2, 1, w/2-2, h-3); - XDrawLine(scr->display, pix, W_GC(scr->white), w/2-1, 0, w/2-1, h-3); + XDrawLine(scr->display, pix, WMColorGC(scr->white), 1, 0, 1, h-3); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), w/2-2, 1, w/2-2, h-3); + XDrawLine(scr->display, pix, WMColorGC(scr->white), w/2-1, 0, w/2-1, h-3); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), w-3, 0, w-3, h-2); - XDrawLine(scr->display, pix, W_GC(scr->black), w-2, 0, w-2, h-2); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), w-1, 0, w-1, h-1); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), w-3, 0, w-3, h-2); + XDrawLine(scr->display, pix, WMColorGC(scr->black), w-2, 0, w-2, h-2); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), w-1, 0, w-1, h-1); - XDrawLine(scr->display, pix, W_GC(scr->black), 1, h-1, w/2+1, h-1); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), 1, h-2, w/2-2, h-2); - XDrawLine(scr->display, pix, W_GC(scr->darkGray), w/2, h-2, w-3,h-2); + XDrawLine(scr->display, pix, WMColorGC(scr->black), 1, h-1, w/2+1, h-1); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), 1, h-2, w/2-2, h-2); + XDrawLine(scr->display, pix, WMColorGC(scr->darkGray), w/2, h-2, w-3,h-2); - XDrawLine(scr->display, pix, W_GC(scr->black), 0, h-1, w-2, h-1); + XDrawLine(scr->display, pix, WMColorGC(scr->black), 0, h-1, w-2, h-1); } if (sPtr->knobPixmap) @@ -339,9 +339,9 @@ paintSlider(Slider *sPtr) #define MAXV sPtr->maxValue #define POSV sPtr->value - bgc = W_GC(scr->black); - wgc = W_GC(scr->white); - lgc = W_GC(scr->gray); + bgc = WMColorGC(scr->black); + wgc = WMColorGC(scr->white); + lgc = WMColorGC(scr->gray); buffer = XCreatePixmap(scr->display, sPtr->view->window, size.width, size.height, scr->depth); @@ -487,12 +487,21 @@ handleActionEvents(XEvent *event, void *data) #else int tmp; - tmp = valueForMousePoint(sPtr, event->xmotion.x, event->xmotion.y); - if (tmp < sPtr->value) - tmp = sPtr->value-1; - else - tmp = sPtr->value+1; - WMSetSliderValue(sPtr, tmp); + if (event->xbutton.button == Button2) { + sPtr->flags.dragging = 1; + + sPtr->value = valueForMousePoint(sPtr, event->xmotion.x, + event->xmotion.y); + paintSlider(sPtr); + } else { + tmp = valueForMousePoint(sPtr, event->xmotion.x, + event->xmotion.y); + if (tmp < sPtr->value) + tmp = sPtr->value-1; + else + tmp = sPtr->value+1; + WMSetSliderValue(sPtr, tmp); + } #endif if (sPtr->flags.continuous && sPtr->action) { diff --git a/WINGs/wtextfield.c b/WINGs/wtextfield.c index 8cf5bc49..cf07da44 100644 --- a/WINGs/wtextfield.c +++ b/WINGs/wtextfield.c @@ -410,14 +410,14 @@ WMSetTextFieldSecure(WMTextField *tPtr, Bool flag) Bool -WMGetTextFieldEnabled(WMTextField *tPtr) +WMGetTextFieldEditable(WMTextField *tPtr) { return tPtr->flags.enabled; } void -WMSetTextFieldEnabled(WMTextField *tPtr, Bool flag) +WMSetTextFieldEditable(WMTextField *tPtr, Bool flag) { tPtr->flags.enabled = flag; @@ -581,15 +581,15 @@ drawRelief(WMView *view, Bool beveled) int width = view->size.width; int height = view->size.height; - dgc = W_GC(scr->darkGray); + dgc = WMColorGC(scr->darkGray); if (!beveled) { XDrawRectangle(dpy, view->window, dgc, 0, 0, width-1, height-1); return; } - wgc = W_GC(scr->white); - lgc = W_GC(scr->gray); + wgc = WMColorGC(scr->white); + lgc = WMColorGC(scr->gray); /* top left */ XDrawLine(dpy, view->window, dgc, 0, 0, width-1, 0); @@ -820,8 +820,7 @@ handleTextFieldKeyPress(TextField *tPtr, XEvent *event) switch (ksym) { case XK_Tab: if (event->xkey.state & ShiftMask) { - if (tPtr->view->prevFocusChain && - tPtr->view->prevFocusChain->flags.mapped) { + if (tPtr->view->prevFocusChain) { W_SetFocusOfTopLevel(W_TopLevelOfView(tPtr->view), tPtr->view->prevFocusChain); tPtr->flags.notIllegalMovement = 1; @@ -829,8 +828,7 @@ handleTextFieldKeyPress(TextField *tPtr, XEvent *event) WMPostNotificationName(WMTextDidEndEditingNotification, tPtr, (void*)WMBacktabTextMovement); } else { - if (tPtr->view->nextFocusChain && - tPtr->view->nextFocusChain->flags.mapped) { + if (tPtr->view->nextFocusChain) { W_SetFocusOfTopLevel(W_TopLevelOfView(tPtr->view), tPtr->view->nextFocusChain); tPtr->flags.notIllegalMovement = 1; diff --git a/WINGs/wview.c b/WINGs/wview.c index c0a3adaa..9e52076c 100644 --- a/WINGs/wview.c +++ b/WINGs/wview.c @@ -103,33 +103,6 @@ adoptChildView(W_View *view, W_View *child) static void -getPosition(Display *dpy, Window win, int *x_ret, int *y_ret) -{ - unsigned foo; - Window bar; - Window parent; - Window *childs; - int x, y; - - XGetGeometry(dpy, win, &bar, &x, &y, &foo, &foo, &foo, &foo); - if (XQueryTree(dpy, win, &bar, &parent, &childs, &foo)) { - int px, py; - - XFree(childs); - if (parent != bar) { - getPosition(dpy, parent, &px, &py); - - x += px; - y += py; - } - } - - *x_ret = x; - *y_ret = y; -} - - -static void handleEvents(XEvent *event, void *data) { W_View *view = (W_View*)data; @@ -154,8 +127,12 @@ handleEvents(XEvent *event, void *data) view->pos.x = event->xconfigure.x; view->pos.y = event->xconfigure.y; } else { - getPosition(view->screen->display, view->window, - &view->pos.x, &view->pos.y); + Window foo; + + XTranslateCoordinates(view->screen->display, + view->window, view->screen->rootWin, + event->xconfigure.x, event->xconfigure.y, + &view->pos.x, &view->pos.y, &foo); } } } diff --git a/WPrefs.app/Appearance.c b/WPrefs.app/Appearance.c index 40d6ed32..f6086fa5 100644 --- a/WPrefs.app/Appearance.c +++ b/WPrefs.app/Appearance.c @@ -1,4 +1,4 @@ -/* TextureAndColor.c- color/texture for titlebar etc. +/* Apperance.c- color/texture for titlebar etc. * * WPrefs - Window Maker Preferences Program * @@ -33,7 +33,7 @@ typedef struct _Panel { WMWindow *win; - WMLabel *prevL; + WMButton *prevB; WMPopUpButton *secP; @@ -41,10 +41,30 @@ typedef struct _Panel { WMLabel *texL; WMList *texLs; - WMPopUpButton *cmdP; - WMTextField *texT; - + WMButton *newB; WMButton *editB; + WMButton *ripB; + WMButton *delB; + + + proplist_t ftitleTex; + proplist_t utitleTex; + proplist_t ptitleTex; + proplist_t iconTex; + proplist_t menuTex; + proplist_t mtitleTex; + proplist_t backTex; + + int ftitleIndex; + int utitleIndex; + int ptitleIndex; + int iconIndex; + int menuIndex; + int mtitleIndex; + int backIndex; + + WMFont *normalFont; + WMFont *selectedFont; /* for preview shit */ Pixmap preview; @@ -59,9 +79,13 @@ typedef struct _Panel { - #define ICON_FILE "appearance" +#define TNEW_FILE "tnew" +#define TDEL_FILE "tdel" +#define TEDIT_FILE "tedit" +#define TEXTR_FILE "textr" + #define FTITLE (1<<0) #define UTITLE (1<<1) @@ -136,12 +160,62 @@ getStrArrayForKey(char *key) } #endif + + +static void +newTexture(WMButton *bPtr, void *data) +{ + _Panel *panel = (_Panel*)data; + + +} + + +static void +changePage(WMWidget *w, void *data) +{ + _Panel *panel = (_Panel*)data; + int section; + + section = WMGetPopUpButtonSelectedItem(panel->secP); + + WMSelectListItem(panel->texLs, section); + +} + + +static void +selectTexture(WMWidget *w, void *data) +{ + _Panel *panel = (_Panel*)data; + int section; + + section = WMGetListSelectedItemRow(panel->secP); + + +} + +static void +fillTextureList(WMList *lPtr) +{ + proplist_t textures; + WMUserDefaults *udb = WMGetStandardUserDefaults(); + + textures = WMGetUDObjectForKey(udb, "Textures"); + + if (!textures) + return; + + +} + + static void createPanel(Panel *p) { _Panel *panel = (_Panel*)p; WMColor *color; - WMFont *boldFont; + WMFont *font; WMScreen *scr = WMWidgetScreen(panel->win); panel->frame = WMCreateFrame(panel->win); @@ -149,25 +223,31 @@ createPanel(Panel *p) WMMoveWidget(panel->frame, FRAME_LEFT, FRAME_TOP); /* preview box */ - panel->prevL = WMCreateLabel(panel->frame); - WMResizeWidget(panel->prevL, 260, 190); - WMMoveWidget(panel->prevL, 10, 10); - WMSetLabelRelief(panel->prevL, WRSunken); + panel->prevB = WMCreateCommandButton(panel->frame); + WMResizeWidget(panel->prevB, 260, 165); + WMMoveWidget(panel->prevB, 15, 10); + WMSetButtonImagePosition(panel->prevB, WIPImageOnly); panel->secP = WMCreatePopUpButton(panel->frame); - WMResizeWidget(panel->secP, 242, 20); - WMMoveWidget(panel->secP, 10, 207); -/* WMSetPopUpButtonAction(panel->secP, changePage, panel); - */ - + WMResizeWidget(panel->secP, 260, 20); + WMMoveWidget(panel->secP, 15, 180); + WMSetPopUpButtonSelectedItem(panel->secP, 0); + WMAddPopUpButtonItem(panel->secP, _("Titlebar of Focused Window")); + WMAddPopUpButtonItem(panel->secP, _("Titlebar of Unfocused Windows")); + WMAddPopUpButtonItem(panel->secP, _("Titlebar of Focused Window's Owner")); + WMAddPopUpButtonItem(panel->secP, _("Titlebar of Menus")); + WMAddPopUpButtonItem(panel->secP, _("Menu Items")); + WMAddPopUpButtonItem(panel->secP, _("Icon Background")); + WMAddPopUpButtonItem(panel->secP, _("Workspace Backgrounds")); + WMSetPopUpButtonAction(panel->secP, changePage, panel); /* texture list */ - boldFont = WMBoldSystemFontOfSize(scr, 12); + font = WMBoldSystemFontOfSize(scr, 12); panel->texL = WMCreateLabel(panel->frame); WMResizeWidget(panel->texL, 225, 18); WMMoveWidget(panel->texL, 285, 10); - WMSetLabelFont(panel->texL, boldFont); + WMSetLabelFont(panel->texL, font); WMSetLabelText(panel->texL, _("Textures")); WMSetLabelRelief(panel->texL, WRSunken); WMSetLabelTextAlignment(panel->texL, WACenter); @@ -178,31 +258,52 @@ createPanel(Panel *p) WMSetLabelTextColor(panel->texL, color); WMReleaseColor(color); - WMReleaseFont(boldFont); - + WMReleaseFont(font); panel->texLs = WMCreateList(panel->frame); WMResizeWidget(panel->texLs, 225, 144); WMMoveWidget(panel->texLs, 285, 30); + + /* command buttons */ - panel->cmdP = WMCreatePopUpButton(panel->frame); - WMResizeWidget(panel->cmdP, 225, 20); - WMMoveWidget(panel->cmdP, 285, 180); - WMSetPopUpButtonPullsDown(panel->cmdP, True); - WMSetPopUpButtonText(panel->cmdP, _("Texture Commands")); - WMAddPopUpButtonItem(panel->cmdP, _("Create New")); - WMAddPopUpButtonItem(panel->cmdP, _("Add From Text Field")); - WMAddPopUpButtonItem(panel->cmdP, _("Remove Selected")); - WMAddPopUpButtonItem(panel->cmdP, _("Extract From File")); + font = WMSystemFontOfSize(scr, 10); - panel->editB = WMCreateCommandButton(panel->frame); - WMResizeWidget(panel->editB, 64, 20); - WMMoveWidget(panel->editB, 260, 207); - WMSetButtonText(panel->editB, _("Browse...")); - panel->texT = WMCreateTextField(panel->frame); - WMResizeWidget(panel->texT, 176, 20); - WMMoveWidget(panel->texT, 330, 207); + panel->newB = WMCreateCommandButton(panel->frame); + WMResizeWidget(panel->newB, 56, 48); + WMMoveWidget(panel->newB, 285, 180); + WMSetButtonFont(panel->newB, font); + WMSetButtonImagePosition(panel->newB, WIPAbove); + WMSetButtonText(panel->newB, _("New")); + SetButtonAlphaImage(scr, panel->newB, TNEW_FILE); + + panel->ripB = WMCreateCommandButton(panel->frame); + WMResizeWidget(panel->ripB, 56, 48); + WMMoveWidget(panel->ripB, 341, 180); + WMSetButtonFont(panel->ripB, font); + WMSetButtonImagePosition(panel->ripB, WIPAbove); + WMSetButtonText(panel->ripB, _("Extract...")); + SetButtonAlphaImage(scr, panel->ripB, TEXTR_FILE); + + panel->editB = WMCreateCommandButton(panel->frame); + WMResizeWidget(panel->editB, 56, 48); + WMMoveWidget(panel->editB, 397, 180); + WMSetButtonFont(panel->editB, font); + WMSetButtonImagePosition(panel->editB, WIPAbove); + WMSetButtonText(panel->editB, _("Edit")); + SetButtonAlphaImage(scr, panel->editB, TEDIT_FILE); + WMSetButtonEnabled(panel->editB, False); + + panel->delB = WMCreateCommandButton(panel->frame); + WMResizeWidget(panel->delB, 56, 48); + WMMoveWidget(panel->delB, 453, 180); + WMSetButtonFont(panel->delB, font); + WMSetButtonImagePosition(panel->delB, WIPAbove); + WMSetButtonText(panel->delB, _("Delete")); + SetButtonAlphaImage(scr, panel->delB, TDEL_FILE); + WMSetButtonEnabled(panel->delB, False); + + WMReleaseFont(font); /**/ @@ -211,8 +312,65 @@ createPanel(Panel *p) WMSetPopUpButtonSelectedItem(panel->secP, 0); + showData(panel); + + fillTextureList(panel->texLs); + +} + +static proplist_t +setupTextureFor(WMList *list, char *key, char *defValue, char *title) +{ + WMListItem *item; + char *tex, *str; + proplist_t prop; + prop = GetObjectForKey(key); + if (!prop) { + prop = PLMakeString(defValue); + } + tex = PLGetDescription(prop); + str = wstrappend(title, tex); + free(tex); + item = WMAddListItem(list, str); + free(str); + item->clientData = prop; + + return prop; +} + +static void +showData(_Panel *panel) +{ + panel->ftitleTex = setupTextureFor(panel->texLs, "FTitleBack", + "(solid, black)", "[Focused]:"); + panel->ftitleIndex = 0; + + panel->utitleTex = setupTextureFor(panel->texLs, "UTitleBack", + "(solid, gray)", "[Unfocused]:"); + panel->utitleIndex = 1; + + panel->ptitleTex = setupTextureFor(panel->texLs, "PTitleBack", + "(solid, \"#616161\")", + "[Owner of Focused]:"); + panel->ptitleIndex = 2; + + panel->mtitleTex = setupTextureFor(panel->texLs, "MenuTitleBack", + "(solid, black)", "[Menu Title]:"); + panel->mtitleIndex = 3; + + panel->menuTex = setupTextureFor(panel->texLs, "MenuTextBack", + "(solid, gray)", "[Menu Item]:"); + panel->menuIndex = 4; + + panel->iconTex = setupTextureFor(panel->texLs, "IconBack", + "(solid, gray)", "[Icon]:"); + panel->iconIndex = 5; + + panel->backTex = setupTextureFor(panel->texLs, "WorkspaceBack", + "(solid, black)", "[Workspace]:"); + panel->backIndex = 6; } diff --git a/WPrefs.app/Makefile.am b/WPrefs.app/Makefile.am index 7982c2f6..037f240a 100644 --- a/WPrefs.app/Makefile.am +++ b/WPrefs.app/Makefile.am @@ -30,7 +30,6 @@ WPrefs_SOURCES = \ Paths.c \ Preferences.c \ Text.c \ - TextureAndColor.c \ TexturePanel.c \ TexturePanel.h \ Themes.c \ diff --git a/WPrefs.app/Makefile.in b/WPrefs.app/Makefile.in index 0e163ad1..68c4f3a3 100644 --- a/WPrefs.app/Makefile.in +++ b/WPrefs.app/Makefile.in @@ -101,7 +101,7 @@ wpdata_DATA = WPrefs.tiff WPrefs.xpm EXTRA_DIST = $(wpdata_DATA) TexturePanel.icons -WPrefs_SOURCES = main.c WPrefs.c WPrefs.h Appearance.c Configurations.c Expert.c Focus.c Icons.c KeyboardSettings.c KeyboardShortcuts.c Menu.c MenuPreferences.c MouseSettings.c NoMenuAlert.c Paths.c Preferences.c Text.c TextureAndColor.c TexturePanel.c TexturePanel.h Themes.c WindowHandling.c Workspace.c double.c double.h editmenu.c editmenu.h MenuGuru.c xmodifier.c +WPrefs_SOURCES = main.c WPrefs.c WPrefs.h Appearance.c Configurations.c Expert.c Focus.c Icons.c KeyboardSettings.c KeyboardShortcuts.c Menu.c MenuPreferences.c MouseSettings.c NoMenuAlert.c Paths.c Preferences.c Text.c TexturePanel.c TexturePanel.h Themes.c WindowHandling.c Workspace.c double.c double.h editmenu.c editmenu.h MenuGuru.c xmodifier.c CPPFLAGS = @CPPFLAGS@ -DLOCALEDIR=\"$(NLSDIR)\" @@ -128,8 +128,8 @@ X_PRE_LIBS = @X_PRE_LIBS@ WPrefs_OBJECTS = main.o WPrefs.o Appearance.o Configurations.o Expert.o \ Focus.o Icons.o KeyboardSettings.o KeyboardShortcuts.o Menu.o \ MenuPreferences.o MouseSettings.o NoMenuAlert.o Paths.o Preferences.o \ -Text.o TextureAndColor.o TexturePanel.o Themes.o WindowHandling.o \ -Workspace.o double.o editmenu.o MenuGuru.o xmodifier.o +Text.o TexturePanel.o Themes.o WindowHandling.o Workspace.o double.o \ +editmenu.o MenuGuru.o xmodifier.o WPrefs_LDFLAGS = CFLAGS = @CFLAGS@ COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) diff --git a/WPrefs.app/Menu.c b/WPrefs.app/Menu.c index 9d580725..fa1e6abc 100644 --- a/WPrefs.app/Menu.c +++ b/WPrefs.app/Menu.c @@ -1347,6 +1347,7 @@ showData(_Panel *panel) if (!menu || !PLIsArray(menu)) { if (AskMenuCopy(panel->win)) { panel->dontSave = 0; + panel->unsaved = 1; pmenu = getDefaultMenu(panel, &hasWSMenu); } else { diff --git a/WPrefs.app/MouseSettings.c b/WPrefs.app/MouseSettings.c index bfaaaa58..fed3f0c4 100644 --- a/WPrefs.app/MouseSettings.c +++ b/WPrefs.app/MouseSettings.c @@ -55,6 +55,8 @@ typedef struct _Panel { WMFrame *ddelaF; WMButton *ddelaB[5]; + WMTextField *ddelaT; + WMLabel *ddelaL; DoubleTest *tester; WMFrame *menuF; @@ -143,7 +145,8 @@ speedClick(WMWidget *w, void *data) tmp = WMGetTextFieldText(panel->acceT); if (sscanf(tmp, "%f", &accel)!=1 || accel < 0) { - WMRunAlertPanel(WMWidgetScreen(w), GetWindow(panel), _("Error"), + WMRunAlertPanel(WMWidgetScreen(panel->acceT), GetWindow(panel), + _("Error"), _("Invalid mouse acceleration value. Must be a positive real value."), _("OK"), NULL, NULL); free(tmp); @@ -192,12 +195,16 @@ doubleClick(WMWidget *w, void *data) _Panel *panel = (_Panel*)data; int i; extern _WINGsConfiguration WINGsConfiguration; + char buffer[32]; for (i=0; i<5; i++) { if (panel->ddelaB[i]==w) break; } WINGsConfiguration.doubleClickDelay = DELAY(i); + + sprintf(buffer, "%i", DELAY(i)); + WMSetTextFieldText(panel->ddelaT, buffer); } @@ -302,26 +309,33 @@ showData(_Panel *panel) } sprintf(buffer, "%i", a); WMSetTextFieldText(panel->threT, buffer); - /* find best match */ - a = 0; + + a = -1; for (i=0; i<5; i++) { - if (fabs((0.5+((float)i*0.5))-accel) < fabs((0.5+((float)a*0.5))-accel)) + if (0.5+(float)i*0.5 == accel) a = i; } - WMPerformButtonClick(panel->speedB[a]); - panel->lastClickedSpeed = panel->speedB[a]; + if (a >= 0) { + WMPerformButtonClick(panel->speedB[a]); + panel->lastClickedSpeed = panel->speedB[a]; + } panel->acceleration = accel; + sprintf(buffer, "%.2f", accel); + WMSetTextFieldText(panel->acceT, buffer); speedClick(panel->lastClickedSpeed, panel); /**/ b = GetIntegerForKey("DoubleClickTime"); /* find best match */ - a = 0; + a = -1; for (i=0; i<5; i++) { - if (abs(b - DELAY(i)) < abs(b - DELAY(a))) + if (DELAY(i) == b) a = i; } - WMPerformButtonClick(panel->ddelaB[a]); + if (a >= 0) + WMPerformButtonClick(panel->ddelaB[a]); + sprintf(buffer, "%i", b); + WMSetTextFieldText(panel->ddelaT, buffer); /**/ str = GetStringForKey("ModifierKey"); @@ -577,13 +591,14 @@ createPanel(Panel *p) free(buf2); panel->acceL = WMCreateLabel(panel->speedF); - WMResizeWidget(panel->acceL, 80, 16); + WMResizeWidget(panel->acceL, 70, 16); WMMoveWidget(panel->acceL, 10, 67); + WMSetLabelTextAlignment(panel->acceL, WARight); WMSetLabelText(panel->acceL, _("Acceler.:")); panel->acceT = WMCreateTextField(panel->speedF); - WMResizeWidget(panel->acceT, 35, 20); - WMMoveWidget(panel->acceT, 85, 65); + WMResizeWidget(panel->acceT, 40, 20); + WMMoveWidget(panel->acceT, 80, 65); WMAddNotificationObserver(returnPressed, panel, WMTextDidEndEditingNotification, panel->acceT); @@ -591,6 +606,7 @@ createPanel(Panel *p) panel->threL = WMCreateLabel(panel->speedF); WMResizeWidget(panel->threL, 80, 16); WMMoveWidget(panel->threL, 120, 67); + WMSetLabelTextAlignment(panel->threL, WARight); WMSetLabelText(panel->threL, _("Threshold:")); panel->threT = WMCreateTextField(panel->speedF); @@ -652,7 +668,27 @@ createPanel(Panel *p) panel->tester = CreateDoubleTest(panel->ddelaF, _("Test")); WMResizeWidget(panel->tester, 84, 29); - WMMoveWidget(panel->tester, 85, 55); + WMMoveWidget(panel->tester, 35, 55); + + panel->ddelaT = WMCreateTextField(panel->ddelaF); + WMResizeWidget(panel->ddelaT, 40, 20); + WMMoveWidget(panel->ddelaT, 140, 60); + + panel->ddelaL = WMCreateLabel(panel->ddelaF); + WMResizeWidget(panel->ddelaL, 40, 16); + WMMoveWidget(panel->ddelaL, 185, 65); + { + WMFont *font; + WMColor *color; + + font = WMSystemFontOfSize(scr, 10); + color = WMDarkGrayColor(scr); + WMSetLabelTextColor(panel->ddelaL, color); + WMSetLabelFont(panel->ddelaL, font); + WMReleaseFont(font); + WMReleaseColor(color); + } + WMSetLabelText(panel->ddelaL, "msec"); WMMapSubwidgets(panel->ddelaF); @@ -878,11 +914,9 @@ storeData(_Panel *panel) free(tmp); } - for (i=0; i<5; i++) { - if (WMGetButtonSelected(panel->ddelaB[i])) - break; - } - SetIntegerForKey(DELAY(i), "DoubleClickTime"); + tmp = WMGetTextFieldText(panel->ddelaT); + if (sscanf(tmp, "%i", &i) == 1 && i > 0) + SetIntegerForKey(i, "DoubleClickTime"); SetBoolForKey(WMGetButtonSelected(panel->disaB), "DisableWSMouseActions"); diff --git a/WPrefs.app/NoMenuAlert.c b/WPrefs.app/NoMenuAlert.c index fd8809f7..62230395 100644 --- a/WPrefs.app/NoMenuAlert.c +++ b/WPrefs.app/NoMenuAlert.c @@ -42,15 +42,15 @@ typedef struct NoMenuPanel { "This either means that there is a syntax error in it or that "\ "the menu is in a format not supported by WPrefs (WPrefs only "\ "supports property list menus).\n"\ - " If you want to change the current menu, please read "\ - "the '%s' file, press 'Keep Current Menu' and edit it with a "\ + " If you want to keep using the current menu, please read "\ + "the '%s/%s' file, press 'Keep Current Menu' and edit it with a "\ "text editor.\n"\ " If you want to use this editor, press 'Copy Default Menu'. "\ "It will copy the default menu and will instruct Window Maker "\ "to use it instead of the current one.\n"\ " If you want more flexibility, keep using the current one "\ "as it allows you to use C preprocessor (cpp) macros, while being "\ - "easy to edit." + "easy to edit. Window Maker supports both formats." static void @@ -79,7 +79,7 @@ Bool AskMenuCopy(WMWindow *wwin) { NoMenuPanel panel; - char buffer[1024]; + char buffer[2048]; panel.wwin = WMCreatePanelForWindow(wwin, "noMenuAlert"); WMResizeWidget(panel.wwin, 430, 260); @@ -90,7 +90,8 @@ AskMenuCopy(WMWindow *wwin) WMResizeWidget(panel.text, 370, 200); WMMoveWidget(panel.text, 30, 20); - sprintf(buffer, _(MESSAGE_TEXT), "shit/ewq/ewq/rweq"); + sprintf(buffer, _(MESSAGE_TEXT), wusergnusteppath(), + "Library/WindowMaker/README"); WMSetLabelText(panel.text, buffer); panel.copyBtn = WMCreateCommandButton(panel.wwin); diff --git a/WPrefs.app/TextureAndColor.c b/WPrefs.app/TextureAndColor.c deleted file mode 100644 index 1b792011..00000000 --- a/WPrefs.app/TextureAndColor.c +++ /dev/null @@ -1,686 +0,0 @@ -/* TextureAndColor.c- color/texture for titlebar etc. - * - * WPrefs - Window Maker Preferences Program - * - * Copyright (c) 1998 Alfredo K. Kojima - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, - * USA. - */ - - -#include "WPrefs.h" - -#include "TexturePanel.h" - -typedef struct _Panel { - WMFrame *frame; - char *sectionName; - - CallbackRec callbacks; - - WMWindow *win; - - WMPopUpButton *secP; - - WMLabel *prevL; - - /* window titlebar */ - WMFrame *focF; - WMColorWell *focC; - WMLabel *focL; - WMTextField *focT; - WMLabel *foc2L; - WMButton *focB; - - WMFrame *unfF; - WMColorWell *unfC; - WMLabel *unfL; - WMTextField *unfT; - WMLabel *unf2L; - WMButton *unfB; - - WMFrame *ownF; - WMColorWell *ownC; - WMLabel *ownL; - WMTextField *ownT; - WMLabel *own2L; - WMButton *ownB; - - /* menu title */ - WMFrame *backF; - WMTextField *backT; - WMButton *backB; - - WMFrame *textF; - WMColorWell *textC; - - /* menu items */ - WMFrame *unsF; - WMTextField *unsT; - WMButton *unsB; - WMLabel *unsL; - WMColorWell *unsnC; - WMLabel *unsnL; - WMColorWell *unsdC; - WMLabel *unsdL; - - WMFrame *selF; - WMColorWell *seltC; - WMLabel *seltL; - WMColorWell *selbC; - WMLabel *selbL; - - /* workspace/clip */ - WMFrame *workF; - WMTextField *workT; - WMButton *workB; - - WMFrame *clipF; - WMColorWell *clipnC; - WMColorWell *clipcC; - WMLabel *clipnL; - WMLabel *clipcL; - - /* icon */ - WMFrame *iconF; - WMTextField *iconT; - WMButton *iconB; - - Pixmap preview; - Pixmap ftitle; - Pixmap utitle; - Pixmap otitle; - Pixmap icon; - Pixmap back; - Pixmap mtitle; - Pixmap mitem; -} _Panel; - - - - -#define ICON_FILE "appearance" - - -#define FTITLE (1<<0) -#define UTITLE (1<<1) -#define OTITLE (1<<2) -#define ICON (1<<3) -#define BACK (1<<4) -#define MTITLE (1<<5) -#define MITEM (1<<6) -#define EVERYTHING 0xff - - -static Pixmap -renderTexture(_Panel *panel, char *texture, int width, int height, - Bool bordered) -{ - return None; -} - - -static void -updatePreviewBox(_Panel *panel, int elements) -{ - WMScreen *scr = WMWidgetScreen(panel->win); - Display *dpy = WMScreenDisplay(scr); - /* RContext *rc = WMScreenRContext(scr);*/ - int refresh = 0; - char *tmp; - - if (!panel->preview) { - panel->preview = XCreatePixmap(dpy, WMWidgetXID(panel->win), - 220-4, 185-4, WMScreenDepth(scr)); - - refresh = -1; - } - - if (elements & FTITLE) { - if (panel->ftitle) - XFreePixmap(dpy, panel->ftitle); - - tmp = WMGetTextFieldText(panel->focT); - panel->ftitle = renderTexture(panel, tmp, 180, 20, True); - free(tmp); - } - - /* have to repaint everything to make things simple, eliminating - * clipping stuff */ - if (refresh) { - - } - - if (refresh<0) { - WMPixmap *pix; - pix = WMCreatePixmapFromXPixmaps(scr, panel->preview, None, - 220-4, 185-4, WMScreenDepth(scr)); - - WMSetLabelImage(panel->prevL, pix); - WMReleasePixmap(pix); - } -} - - - -static void -changePage(WMWidget *self, void *data) -{ - int i; - _Panel *panel = (_Panel*)data; - - i = WMGetPopUpButtonSelectedItem(self); - - if (i==0) { - WMMapWidget(panel->focF); - WMMapWidget(panel->unfF); - WMMapWidget(panel->ownF); - } else if (i==1) { - WMMapWidget(panel->backF); - WMMapWidget(panel->textF); - } else if (i==2) { - WMMapWidget(panel->unsF); - WMMapWidget(panel->selF); - } else if (i==3) { - WMMapWidget(panel->workF); - WMMapWidget(panel->clipF); - } else if (i==4) { - WMMapWidget(panel->iconF); - } - - if (i!=0) { - WMUnmapWidget(panel->focF); - WMUnmapWidget(panel->unfF); - WMUnmapWidget(panel->ownF); - } - if (i!=1) { - WMUnmapWidget(panel->backF); - WMUnmapWidget(panel->textF); - } - if (i!=2) { - WMUnmapWidget(panel->unsF); - WMUnmapWidget(panel->selF); - } - if (i!=3) { - WMUnmapWidget(panel->workF); - WMUnmapWidget(panel->clipF); - } - if (i!=4) { - WMUnmapWidget(panel->iconF); - } -} - - -static char* -getStrArrayForKey(char *key) -{ - proplist_t v; - - v = GetObjectForKey(key); - if (!v) - return NULL; - - return PLGetDescription(v); -} - - -static void -showData(_Panel *panel) -{ - char *str; - WMScreen *scr = WMWidgetScreen(panel->win); - WMColor *color; - - str = GetStringForKey("FTitleColor"); - if (!str) - str = "white"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->focC, color); - WMReleaseColor(color); - - str = GetStringForKey("PTitleColor"); - if (!str) - str = "white"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->ownC, color); - WMReleaseColor(color); - - str = GetStringForKey("UTitleColor"); - if (!str) - str = "black"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->unfC, color); - WMReleaseColor(color); - - - str = getStrArrayForKey("FTitleBack"); - if (!str) - str = wstrdup("(solid, black)"); - WMSetTextFieldText(panel->focT, str); - free(str); - - str = getStrArrayForKey("PTitleBack"); - if (!str) - str = wstrdup("(solid, gray40)"); - WMSetTextFieldText(panel->ownT, str); - free(str); - - str = getStrArrayForKey("UTitleBack"); - if (!str) - str = wstrdup("(solid, grey66)"); - WMSetTextFieldText(panel->unfT, str); - free(str); - - /**/ - - str = GetStringForKey("MenuTitleColor"); - if (!str) - str = "white"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->textC, color); - WMReleaseColor(color); - - str = getStrArrayForKey("MenuTitleBack"); - if (!str) - str = wstrdup("(solid, black)"); - WMSetTextFieldText(panel->backT, str); - free(str); - - /**/ - - str = getStrArrayForKey("MenuTextBack"); - if (!str) - str = wstrdup("gray66"); - WMSetTextFieldText(panel->unsT, str); - free(str); - - str = GetStringForKey("MenuTextColor"); - if (!str) - str = "black"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->unsnC, color); - WMReleaseColor(color); - - str = GetStringForKey("MenuDisabledColor"); - if (!str) - str = "gray40"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->unsdC, color); - WMReleaseColor(color); - - str = GetStringForKey("HighlightTextColor"); - if (!str) - str = "white"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->seltC, color); - WMReleaseColor(color); - - str = GetStringForKey("HighlightColor"); - if (!str) - str = "black"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->selbC, color); - WMReleaseColor(color); - - /**/ - - str = getStrArrayForKey("WorkspaceBack"); - WMSetTextFieldText(panel->workT, str); - if (str) - free(str); - - - str = GetStringForKey("ClipTitleColor"); - if (!str) - str = "black"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->clipnC, color); - WMReleaseColor(color); - - str = GetStringForKey("CClipTitleColor"); - if (!str) - str = "grey40"; - color = WMCreateNamedColor(scr, str, True); - WMSetColorWellColor(panel->clipcC, color); - WMReleaseColor(color); - - /**/ - - str = getStrArrayForKey("IconBack"); - if (!str) - str = wstrdup("(solid, gray66)"); - WMSetTextFieldText(panel->iconT, str); - free(str); -} - - -static void -createPanel(Panel *p) -{ - _Panel *panel = (_Panel*)p; - - panel->frame = WMCreateFrame(panel->win); - WMResizeWidget(panel->frame, FRAME_WIDTH, FRAME_HEIGHT); - WMMoveWidget(panel->frame, FRAME_LEFT, FRAME_TOP); - - panel->secP = WMCreatePopUpButton(panel->frame); - WMResizeWidget(panel->secP, 220, 20); - WMMoveWidget(panel->secP, 15, 10); - WMSetPopUpButtonAction(panel->secP, changePage, panel); - - WMAddPopUpButtonItem(panel->secP, _("Window Title Bar")); - WMAddPopUpButtonItem(panel->secP, _("Menu Title Bar")); - WMAddPopUpButtonItem(panel->secP, _("Menu Items")); - WMAddPopUpButtonItem(panel->secP, _("Workspace/Clip")); - WMAddPopUpButtonItem(panel->secP, _("Icons")); - - panel->prevL = WMCreateLabel(panel->frame); - WMResizeWidget(panel->prevL, 220, 185); - WMMoveWidget(panel->prevL, 15, 40); - WMSetLabelRelief(panel->prevL, WRSunken); - - /* window titlebar */ - panel->focF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->focF, 265, 70); - WMMoveWidget(panel->focF, 245, 5); - WMSetFrameTitle(panel->focF, _("Focused Window")); - - panel->focC = WMCreateColorWell(panel->focF); - WMResizeWidget(panel->focC, 60, 35); - WMMoveWidget(panel->focC, 15, 15); - - panel->focT = WMCreateTextField(panel->focF); - WMResizeWidget(panel->focT, 116, 20); - WMMoveWidget(panel->focT, 85, 25); - - panel->foc2L = WMCreateLabel(panel->focF); - WMResizeWidget(panel->foc2L, 165, 16); - WMMoveWidget(panel->foc2L, 90, 50); - WMSetLabelText(panel->foc2L, _("Texture")); - WMSetLabelTextAlignment(panel->foc2L, WACenter); - - panel->focL = WMCreateLabel(panel->focF); - WMResizeWidget(panel->focL, 100, 16); - WMMoveWidget(panel->focL, 15, 50); - WMSetLabelText(panel->focL, _("Text Color")); - - panel->focB = WMCreateCommandButton(panel->focF); - WMResizeWidget(panel->focB, 48, 22); - WMMoveWidget(panel->focB, 205, 24); - WMSetButtonText(panel->focB, _("Set...")); - - WMMapSubwidgets(panel->focF); - /**/ - panel->unfF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->unfF, 265, 70); - WMMoveWidget(panel->unfF, 245, 80); - WMSetFrameTitle(panel->unfF, _("Unfocused Window")); - - panel->unfC = WMCreateColorWell(panel->unfF); - WMResizeWidget(panel->unfC, 60, 35); - WMMoveWidget(panel->unfC, 15, 15); - - panel->unfT = WMCreateTextField(panel->unfF); - WMResizeWidget(panel->unfT, 116, 20); - WMMoveWidget(panel->unfT, 85, 25); - - panel->unf2L = WMCreateLabel(panel->unfF); - WMResizeWidget(panel->unf2L, 165, 16); - WMMoveWidget(panel->unf2L, 90, 50); - WMSetLabelText(panel->unf2L, _("Texture")); - WMSetLabelTextAlignment(panel->unf2L, WACenter); - - panel->unfL = WMCreateLabel(panel->unfF); - WMResizeWidget(panel->unfL, 100, 16); - WMMoveWidget(panel->unfL, 15, 50); - WMSetLabelText(panel->unfL, _("Text Color")); - - panel->unfB = WMCreateCommandButton(panel->unfF); - WMResizeWidget(panel->unfB, 48, 22); - WMMoveWidget(panel->unfB, 205, 24); - WMSetButtonText(panel->unfB, _("Set...")); - - WMMapSubwidgets(panel->unfF); - /**/ - panel->ownF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->ownF, 265, 70); - WMMoveWidget(panel->ownF, 245, 155); - WMSetFrameTitle(panel->ownF, _("Owner of Focused Window")); - - panel->ownC = WMCreateColorWell(panel->ownF); - WMResizeWidget(panel->ownC, 60, 35); - WMMoveWidget(panel->ownC, 15, 15); - - panel->ownT = WMCreateTextField(panel->ownF); - WMResizeWidget(panel->ownT, 116, 20); - WMMoveWidget(panel->ownT, 85, 25); - - panel->own2L = WMCreateLabel(panel->ownF); - WMResizeWidget(panel->own2L, 165, 16); - WMMoveWidget(panel->own2L, 90, 50); - WMSetLabelText(panel->own2L, _("Texture")); - WMSetLabelTextAlignment(panel->own2L, WACenter); - - panel->ownL = WMCreateLabel(panel->ownF); - WMResizeWidget(panel->ownL, 100, 16); - WMMoveWidget(panel->ownL, 15, 50); - WMSetLabelText(panel->ownL, _("Text Color")); - - panel->ownB = WMCreateCommandButton(panel->ownF); - WMResizeWidget(panel->ownB, 48, 22); - WMMoveWidget(panel->ownB, 205, 24); - WMSetButtonText(panel->ownB, _("Set...")); - - WMMapSubwidgets(panel->ownF); - - /***************** Menu Item *****************/ - - panel->unsF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->unsF, 260, 140); - WMMoveWidget(panel->unsF, 250, 5); - WMSetFrameTitle(panel->unsF, _("Unselected Items")); - - panel->unsT = WMCreateTextField(panel->unsF); - WMResizeWidget(panel->unsT, 175, 20); - WMMoveWidget(panel->unsT, 15, 25); - - panel->unsL = WMCreateLabel(panel->unsF); - WMResizeWidget(panel->unsL, 175, 16); - WMMoveWidget(panel->unsL, 15, 50); - WMSetLabelTextAlignment(panel->unsL, WACenter); - WMSetLabelText(panel->unsL, _("Background")); - - panel->unsB = WMCreateCommandButton(panel->unsF); - WMResizeWidget(panel->unsB, 48, 22); - WMMoveWidget(panel->unsB, 200, 24); - WMSetButtonText(panel->unsB, _("Set...")); - - panel->unsnC = WMCreateColorWell(panel->unsF); - WMResizeWidget(panel->unsnC, 60, 40); - WMMoveWidget(panel->unsnC, 40, 75); - - panel->unsnL = WMCreateLabel(panel->unsF); - WMResizeWidget(panel->unsnL, 120, 16); - WMMoveWidget(panel->unsnL, 10, 117); - WMSetLabelTextAlignment(panel->unsnL, WACenter); - WMSetLabelText(panel->unsnL, _("Normal Text")); - - panel->unsdC = WMCreateColorWell(panel->unsF); - WMResizeWidget(panel->unsdC, 60, 40); - WMMoveWidget(panel->unsdC, 160, 75); - - panel->unsdL = WMCreateLabel(panel->unsF); - WMResizeWidget(panel->unsdL, 120, 16); - WMMoveWidget(panel->unsdL, 130, 117); - WMSetLabelTextAlignment(panel->unsdL, WACenter); - WMSetLabelText(panel->unsdL, _("Disabled Text")); - - WMMapSubwidgets(panel->unsF); - - /**/ - - panel->selF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->selF, 260, 75); - WMMoveWidget(panel->selF, 250, 150); - WMSetFrameTitle(panel->selF, _("Selected Items")); - - panel->seltC = WMCreateColorWell(panel->selF); - WMResizeWidget(panel->seltC, 60, 36); - WMMoveWidget(panel->seltC, 40, 20); - - panel->seltL = WMCreateLabel(panel->selF); - WMResizeWidget(panel->seltL, 120, 16); - WMMoveWidget(panel->seltL, 10, 56); - WMSetLabelTextAlignment(panel->seltL, WACenter); - WMSetLabelText(panel->seltL, _("Text")); - - panel->selbC = WMCreateColorWell(panel->selF); - WMResizeWidget(panel->selbC, 60, 36); - WMMoveWidget(panel->selbC, 160, 20); - - panel->selbL = WMCreateLabel(panel->selF); - WMResizeWidget(panel->selbL, 120, 16); - WMMoveWidget(panel->selbL, 130, 56); - WMSetLabelTextAlignment(panel->selbL, WACenter); - WMSetLabelText(panel->selbL, _("Background")); - - WMMapSubwidgets(panel->selF); - - /***************** Menu Title *****************/ - panel->backF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->backF, 260, 110); - WMMoveWidget(panel->backF, 250, 35); - WMSetFrameTitle(panel->backF, _("Menu Title Background")); - - panel->backT = WMCreateTextField(panel->backF); - WMResizeWidget(panel->backT, 210, 20); - WMMoveWidget(panel->backT, 25, 35); - - panel->backB = WMCreateCommandButton(panel->backF); - WMResizeWidget(panel->backB, 50, 24); - WMMoveWidget(panel->backB, 185, 60); - WMSetButtonText(panel->backB, _("Set...")); - - WMMapSubwidgets(panel->backF); - - /**/ - - panel->textF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->textF, 260, 75); - WMMoveWidget(panel->textF, 250, 150); - WMSetFrameTitle(panel->textF, _("Menu Title Text")); - - panel->textC = WMCreateColorWell(panel->textF); - WMResizeWidget(panel->textC, 60, 40); - WMMoveWidget(panel->textC, 100, 20); - - WMMapSubwidgets(panel->textF); - - /***************** Workspace ****************/ - panel->workF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->workF, 260, 90); - WMMoveWidget(panel->workF, 250, 35); - WMSetFrameTitle(panel->workF, _("Workspace Background")); - - panel->workT = WMCreateTextField(panel->workF); - WMResizeWidget(panel->workT, 220, 20); - WMMoveWidget(panel->workT, 20, 25); - - panel->workB = WMCreateCommandButton(panel->workF); - WMResizeWidget(panel->workB, 70, 24); - WMMoveWidget(panel->workB, 170, 55); - WMSetButtonText(panel->workB, _("Change")); - - /**/ - panel->clipF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->clipF, 260, 90); - WMMoveWidget(panel->clipF, 250, 135); - WMSetFrameTitle(panel->clipF, _("Clip Title Text")); - - panel->clipnC = WMCreateColorWell(panel->clipF); - WMResizeWidget(panel->clipnC, 60, 40); - WMMoveWidget(panel->clipnC, 40, 25); - - panel->clipnL = WMCreateLabel(panel->clipF); - WMResizeWidget(panel->clipnL, 120, 16); - WMMoveWidget(panel->clipnL, 10, 70); - WMSetLabelTextAlignment(panel->clipnL, WACenter); - WMSetLabelText(panel->clipnL, _("Normal")); - - panel->clipcC = WMCreateColorWell(panel->clipF); - WMResizeWidget(panel->clipcC, 60, 40); - WMMoveWidget(panel->clipcC, 160, 25); - - panel->clipcL = WMCreateLabel(panel->clipF); - WMResizeWidget(panel->clipcL, 120, 16); - WMMoveWidget(panel->clipcL, 130, 70); - WMSetLabelTextAlignment(panel->clipcL, WACenter); - WMSetLabelText(panel->clipcL, _("Collapsed")); - - WMMapSubwidgets(panel->clipF); - - - - WMMapSubwidgets(panel->workF); - - /***************** Icon *****************/ - panel->iconF = WMCreateFrame(panel->frame); - WMResizeWidget(panel->iconF, 260, 190); - WMMoveWidget(panel->iconF, 250, 35); - WMSetFrameTitle(panel->iconF, _("Icon Background")); - - panel->iconT = WMCreateTextField(panel->iconF); - WMResizeWidget(panel->iconT, 220, 20); - WMMoveWidget(panel->iconT, 20, 80); - - panel->iconB = WMCreateCommandButton(panel->iconF); - WMResizeWidget(panel->iconB, 50, 24); - WMMoveWidget(panel->iconB, 190, 105); - WMSetButtonText(panel->iconB, _("Set...")); - - WMMapSubwidgets(panel->iconF); - /**/ - - WMRealizeWidget(panel->frame); - WMMapSubwidgets(panel->frame); - - WMSetPopUpButtonSelectedItem(panel->secP, 0); - changePage(panel->secP, panel); - - - showData(panel); -} - - - -Panel* -InitTextureAndColor(WMScreen *scr, WMWindow *win) -{ - _Panel *panel; - - panel = wmalloc(sizeof(_Panel)); - memset(panel, 0, sizeof(_Panel)); - - panel->sectionName = _("Texture and Color Preferences"); - - panel->win = win; - - panel->callbacks.createWidgets = createPanel; - - AddSection(panel, ICON_FILE); - - return panel; -} diff --git a/WPrefs.app/TexturePanel.c b/WPrefs.app/TexturePanel.c index 47f359b5..3704634f 100644 --- a/WPrefs.app/TexturePanel.c +++ b/WPrefs.app/TexturePanel.c @@ -2,7 +2,7 @@ * * WPrefs - WindowMaker Preferences Program * - * Copyright (c) 1998 Alfredo K. Kojima + * Copyright (c) 1998, 1999 Alfredo K. Kojima * Copyright (c) 1998 James Thompson * * This program is free software; you can redistribute it and/or modify @@ -82,27 +82,29 @@ typedef struct _TexturePanel { WMAction *cancelAction; void *cancelData; - + } _TexturePanel; -char *WMGetColorWellRGBString(WMColorWell *cPtr) { - char *rgbString; - WMColor *color; - - - rgbString = wmalloc(13); - color = WMGetColorWellColor(cPtr); - - if (color) { - sprintf(rgbString,"rgb:%02x/%02x/%02x", - (WMRedComponentOfColor(color) >> 8), - (WMGreenComponentOfColor(color) >> 8), - (WMBlueComponentOfColor(color) >> 8)); - } - - return rgbString; +char* +WMGetColorWellRGBString(WMColorWell *cPtr) +{ + char *rgbString; + WMColor *color; + + + rgbString = wmalloc(13); + color = WMGetColorWellColor(cPtr); + + if (color) { + sprintf(rgbString,"rgb:%02x/%02x/%02x", + (WMRedComponentOfColor(color) >> 8), + (WMGreenComponentOfColor(color) >> 8), + (WMBlueComponentOfColor(color) >> 8)); + } + + return rgbString; } @@ -123,17 +125,17 @@ notificationObserver(void *self, WMNotification *notif) _TexturePanel *panel = (_TexturePanel*)self; void *object = WMGetNotificationObject(notif); char *text; - + if (WMGetNotificationName(notif) == WMTextDidChangeNotification) { - if (object == panel->pimagT) { - text = WMGetTextFieldText(panel->pimagT); - if (strlen(text)) { - WMSetButtonEnabled(panel->okB, True); - } else { - WMSetButtonEnabled(panel->okB, False); - } - free(text); - } + if (object == panel->pimagT) { + text = WMGetTextFieldText(panel->pimagT); + if (strlen(text)) { + WMSetButtonEnabled(panel->okB, True); + } else { + WMSetButtonEnabled(panel->okB, False); + } + free(text); + } } } @@ -153,12 +155,12 @@ paintListItem(WMList *lPtr, int index, Drawable d, char *text, int state, WMRect height = rect->size.height; x = rect->pos.x; y = rect->pos.y; - + if (state & WLDSSelected) XFillRectangle(dpy, d, WMColorGC(WMWhiteColor(scr)), x, y,width, height); else XClearArea(WMScreenDisplay(scr), d, x, y, width, height, False); - + gc = XCreateGC(dpy, RootWindow(dpy, 0),0,NULL); WMSetColorInGC(WMCreateNamedColor(scr, text, True),gc); XFillRectangle (dpy, d, gc,x+5,y+3,width-8,height-6); @@ -169,95 +171,95 @@ paintListItem(WMList *lPtr, int index, Drawable d, char *text, int state, WMRect static void buttonCallback(WMWidget *self, void *data) { - _TexturePanel *panel = (_TexturePanel*)data; - char *text, *color; - WMOpenPanel *op; - int itemRow; - - WMSetButtonEnabled(panel->okB, True); - - /* Global Buttons */ - - if (self == panel->okB) { - if (panel->okAction) { - (*panel->okAction)(self, panel->okData); - } else { - wwarning ("Texture panel OK button undefined"); - } - } else if (self == panel->cancB) { - if (panel->cancelAction) { - (*panel->cancelAction)(self, panel->cancelData); - } else { - wwarning ("Texture panel CANCEL button undefined"); - } - } else if (self == panel->tsoliB) { - WMMapWidget(panel->scolorF); - WMUnmapWidget(panel->gcolorF); - WMUnmapWidget(panel->gdirF); - WMUnmapWidget(panel->pimagF); - WMUnmapWidget(panel->pcolorF); - WMUnmapWidget(panel->pmodeF); - } else if (self == panel->tgradB) { - WMMapWidget(panel->gcolorF); - WMMapWidget(panel->gdirF); - WMUnmapWidget(panel->scolorF); - WMUnmapWidget(panel->pimagF); - WMUnmapWidget(panel->pcolorF); - WMUnmapWidget(panel->pmodeF); - } else if (self == panel->tpixmB) { - WMMapWidget(panel->pimagF); - WMMapWidget(panel->pcolorF); - WMMapWidget(panel->pmodeF); - WMUnmapWidget(panel->gcolorF); - WMUnmapWidget(panel->gdirF); - WMUnmapWidget(panel->scolorF); - - text = WMGetTextFieldText(panel->pimagT); - if (!strlen(text)) { - WMSetButtonEnabled(panel->okB, False); - } - free(text); - - /* Gradient Panel Buttons */ - - } else if (self == panel->gaddB) { - color = WMGetColorWellRGBString(panel->gcolorW); - itemRow = WMGetListSelectedItemRow(panel->gcolorLs); - WMInsertListItem(panel->gcolorLs,itemRow, color); - free(color); - renderTextureButtons(panel); - - } else if (self == panel->gremB) { - if (WMGetListNumberOfRows(panel->gcolorLs) != 1) { - itemRow = WMGetListSelectedItemRow(panel->gcolorLs); - WMRemoveListItem(panel->gcolorLs,itemRow); - renderTextureButtons(panel); - } + _TexturePanel *panel = (_TexturePanel*)data; + char *text, *color; + WMOpenPanel *op; + int itemRow; - } else if (self == panel->gupdB) { - color = WMGetColorWellRGBString(panel->gcolorW); - itemRow = WMGetListSelectedItemRow(panel->gcolorLs); - WMRemoveListItem(panel->gcolorLs,itemRow); - WMInsertListItem(panel->gcolorLs,itemRow, color); - free(color); - renderTextureButtons(panel); - - /* Pixmap Panel Buttons */ - - } else if (self == panel->pbrowB) { - op = WMGetOpenPanel(WMWidgetScreen(panel->pbrowB)); - if (WMRunModalFilePanelForDirectory(op, NULL, "/usr/local", NULL, NULL)) { - char *path; - path = WMGetFilePanelFileName(op); - WMSetTextFieldText(panel->pimagT, path); - if (strlen(path)) { - WMSetButtonEnabled(panel->okB, True); - } - free(path); + WMSetButtonEnabled(panel->okB, True); + + /* Global Buttons */ + + if (self == panel->okB) { + if (panel->okAction) { + (*panel->okAction)(self, panel->okData); + } else { + wwarning ("Texture panel OK button undefined"); + } + } else if (self == panel->cancB) { + if (panel->cancelAction) { + (*panel->cancelAction)(self, panel->cancelData); + } else { + wwarning ("Texture panel CANCEL button undefined"); + } + } else if (self == panel->tsoliB) { + WMMapWidget(panel->scolorF); + WMUnmapWidget(panel->gcolorF); + WMUnmapWidget(panel->gdirF); + WMUnmapWidget(panel->pimagF); + WMUnmapWidget(panel->pcolorF); + WMUnmapWidget(panel->pmodeF); + } else if (self == panel->tgradB) { + WMMapWidget(panel->gcolorF); + WMMapWidget(panel->gdirF); + WMUnmapWidget(panel->scolorF); + WMUnmapWidget(panel->pimagF); + WMUnmapWidget(panel->pcolorF); + WMUnmapWidget(panel->pmodeF); + } else if (self == panel->tpixmB) { + WMMapWidget(panel->pimagF); + WMMapWidget(panel->pcolorF); + WMMapWidget(panel->pmodeF); + WMUnmapWidget(panel->gcolorF); + WMUnmapWidget(panel->gdirF); + WMUnmapWidget(panel->scolorF); + + text = WMGetTextFieldText(panel->pimagT); + if (!strlen(text)) { + WMSetButtonEnabled(panel->okB, False); + } + free(text); + + /* Gradient Panel Buttons */ + + } else if (self == panel->gaddB) { + color = WMGetColorWellRGBString(panel->gcolorW); + itemRow = WMGetListSelectedItemRow(panel->gcolorLs); + WMInsertListItem(panel->gcolorLs,itemRow, color); + free(color); + renderTextureButtons(panel); + + } else if (self == panel->gremB) { + if (WMGetListNumberOfRows(panel->gcolorLs) != 1) { + itemRow = WMGetListSelectedItemRow(panel->gcolorLs); + WMRemoveListItem(panel->gcolorLs,itemRow); + renderTextureButtons(panel); + } + + } else if (self == panel->gupdB) { + color = WMGetColorWellRGBString(panel->gcolorW); + itemRow = WMGetListSelectedItemRow(panel->gcolorLs); + WMRemoveListItem(panel->gcolorLs,itemRow); + WMInsertListItem(panel->gcolorLs,itemRow, color); + free(color); + renderTextureButtons(panel); + + /* Pixmap Panel Buttons */ + + } else if (self == panel->pbrowB) { + op = WMGetOpenPanel(WMWidgetScreen(panel->pbrowB)); + if (WMRunModalFilePanelForDirectory(op, NULL, "/usr/local", NULL, NULL)) { + char *path; + path = WMGetFilePanelFileName(op); + WMSetTextFieldText(panel->pimagT, path); + if (strlen(path)) { + WMSetButtonEnabled(panel->okB, True); + } + free(path); + } + WMFreeFilePanel(op); } - WMFreeFilePanel(op); - } - + } #if 0 @@ -267,7 +269,7 @@ changePanel(WMWidget *self, void *data) { _TexturePanel *panel = (_TexturePanel*)data; char *text = NULL; - + WMSetButtonEnabled(panel->okB, True); if (self == panel->tsoliB) { WMMapWidget(panel->scolorF); @@ -290,10 +292,10 @@ changePanel(WMWidget *self, void *data) WMUnmapWidget(panel->gcolorF); WMUnmapWidget(panel->gdirF); WMUnmapWidget(panel->scolorF); - + text = WMGetTextFieldText(panel->pimagT); if (!strlen(text)) { - WMSetButtonEnabled(panel->okB, False); + WMSetButtonEnabled(panel->okB, False); } free(text); } @@ -303,28 +305,28 @@ changePanel(WMWidget *self, void *data) static void modifyGradientList(WMWidget *self, void *data) { - _TexturePanel *panel = (_TexturePanel*)data; - char *color = NULL; - int itemRow; - - itemRow = WMGetListSelectedItemRow(panel->gcolorLs); - - color = WMGetColorWellRGBString(panel->gcolorW); - - if (self == panel->gaddB) { - WMInsertListItem(panel->gcolorLs,itemRow, color); - } else if (self == panel->gremB) { - if (WMGetListNumberOfRows(panel->gcolorLs) != 1) { - WMRemoveListItem(panel->gcolorLs,itemRow); - } - - } else { - WMRemoveListItem(panel->gcolorLs,itemRow); - WMInsertListItem(panel->gcolorLs,itemRow, color); - } - free (color); - - renderTextureButtons(panel); + _TexturePanel *panel = (_TexturePanel*)data; + char *color = NULL; + int itemRow; + + itemRow = WMGetListSelectedItemRow(panel->gcolorLs); + + color = WMGetColorWellRGBString(panel->gcolorW); + + if (self == panel->gaddB) { + WMInsertListItem(panel->gcolorLs,itemRow, color); + } else if (self == panel->gremB) { + if (WMGetListNumberOfRows(panel->gcolorLs) != 1) { + WMRemoveListItem(panel->gcolorLs,itemRow); + } + + } else { + WMRemoveListItem(panel->gcolorLs,itemRow); + WMInsertListItem(panel->gcolorLs,itemRow, color); + } + free (color); + + renderTextureButtons(panel); } #endif @@ -332,63 +334,63 @@ modifyGradientList(WMWidget *self, void *data) static void renderTextureButtons(_TexturePanel *panel) { - RColor **colors = NULL; - XColor color; - WMPixmap *icon; - RImage *imgh, *imgv, *imgd; - WMScreen *scr; - - int i, listRows; - - scr = WMWidgetScreen(panel->gcolorLs); - listRows = WMGetListNumberOfRows(panel->gcolorLs); - colors = wmalloc(sizeof(RColor*)*(listRows+1)); - - for (i=0; i < listRows; i++) { - if (!XParseColor(WMScreenDisplay(scr), (WMScreenRContext(scr))->cmap, - wstrdup(WMGetListItem(panel->gcolorLs, i)->text),&color)) { - wfatal("could not parse color \"%s\"\n", WMGetListItem(panel->gcolorLs, i)->text); - exit(1); + RColor **colors = NULL; + XColor color; + WMPixmap *icon; + RImage *imgh, *imgv, *imgd; + WMScreen *scr; + + int i, listRows; + + scr = WMWidgetScreen(panel->gcolorLs); + listRows = WMGetListNumberOfRows(panel->gcolorLs); + colors = wmalloc(sizeof(RColor*)*(listRows+1)); + + for (i=0; i < listRows; i++) { + if (!XParseColor(WMScreenDisplay(scr), (WMScreenRContext(scr))->cmap, + wstrdup(WMGetListItem(panel->gcolorLs, i)->text),&color)) { + wfatal("could not parse color \"%s\"\n", WMGetListItem(panel->gcolorLs, i)->text); + exit(1); + } else { + colors[i] = malloc(sizeof(RColor)); + colors[i]->red = color.red >> 8; + colors[i]->green = color.green >> 8; + colors[i]->blue = color.blue >> 8; + } + } + colors[i] = NULL; + + imgh = RRenderMultiGradient(50, 20, colors, RGRD_HORIZONTAL); + if (!imgh) { + wwarning("internal error:%s", RMessageForError(RErrorCode)); } else { - colors[i] = malloc(sizeof(RColor)); - colors[i]->red = color.red >> 8; - colors[i]->green = color.green >> 8; - colors[i]->blue = color.blue >> 8; + icon = WMCreatePixmapFromRImage(scr, imgh, 120); + RDestroyImage(imgh); + WMSetButtonImage(panel->ghorB, icon); + WMReleasePixmap(icon); } - } - colors[i] = NULL; - - imgh = RRenderMultiGradient(50, 20, colors, RGRD_HORIZONTAL); - if (!imgh) { - wwarning("internal error:%s", RMessageForError(RErrorCode)); - } else { - icon = WMCreatePixmapFromRImage(scr, imgh, 120); - RDestroyImage(imgh); - WMSetButtonImage(panel->ghorB, icon); - WMReleasePixmap(icon); - } - - imgv = RRenderMultiGradient(50, 20, colors, RGRD_VERTICAL); - if (!imgv) { - wwarning("internal error:%s", RMessageForError(RErrorCode)); - } else { - icon = WMCreatePixmapFromRImage(scr, imgv, 120); - RDestroyImage(imgv); - WMSetButtonImage(panel->gverB, icon); - WMReleasePixmap(icon); - } - - imgd = RRenderMultiGradient(50, 20, colors, RGRD_DIAGONAL); - if (!imgd) { - wwarning("internal error:%s", RMessageForError(RErrorCode)); - } else { - icon = WMCreatePixmapFromRImage(scr, imgd, 120); - RDestroyImage(imgd); - WMSetButtonImage(panel->gdiaB, icon); - WMReleasePixmap(icon); - } - - free(colors); + + imgv = RRenderMultiGradient(50, 20, colors, RGRD_VERTICAL); + if (!imgv) { + wwarning("internal error:%s", RMessageForError(RErrorCode)); + } else { + icon = WMCreatePixmapFromRImage(scr, imgv, 120); + RDestroyImage(imgv); + WMSetButtonImage(panel->gverB, icon); + WMReleasePixmap(icon); + } + + imgd = RRenderMultiGradient(50, 20, colors, RGRD_DIAGONAL); + if (!imgd) { + wwarning("internal error:%s", RMessageForError(RErrorCode)); + } else { + icon = WMCreatePixmapFromRImage(scr, imgd, 120); + RDestroyImage(imgd); + WMSetButtonImage(panel->gdiaB, icon); + WMReleasePixmap(icon); + } + + free(colors); } @@ -400,141 +402,141 @@ renderTextureButtons(_TexturePanel *panel) void DestroyTexturePanel(TexturePanel *panel) { - WMUnmapWidget(panel->win); - WMDestroyWidget(panel->win); - free(panel); + WMUnmapWidget(panel->win); + WMDestroyWidget(panel->win); + free(panel); } void ShowTexturePanel(TexturePanel *panel) { - WMMapWidget(panel->win); + WMMapWidget(panel->win); } void HideTexturePanel(TexturePanel *panel) { - WMUnmapWidget(panel->win); + WMUnmapWidget(panel->win); } void SetTexturePanelOkAction(TexturePanel *panel, WMAction *action, void *clientData) { - panel->okAction = action; - panel->okData = clientData; + panel->okAction = action; + panel->okData = clientData; } void SetTexturePanelCancelAction(TexturePanel *panel, WMAction *action, void *clientData) { - panel->cancelAction = action; - panel->cancelData = clientData; + panel->cancelAction = action; + panel->cancelData = clientData; } void SetTexturePanelTexture(TexturePanel *panel, char *texture) { - char *parseString; - char *parseStringPosition; - char *enclosures = "( )"; - char *seperators = " ,\""; - char *filename; - - WMSetButtonSelected(panel->tsoliB, False); - WMSetButtonSelected(panel->tgradB, False); - WMSetButtonSelected(panel->tpixmB, False); - - parseString = wstrdup(texture); - parseStringPosition = parseString; - - parseStringPosition = strtok(parseStringPosition,seperators); - wwarning ("Parsing..."); - - while (parseStringPosition) { - - if (!strpbrk(parseStringPosition,enclosures)) { - if (strcasecmp(parseStringPosition,"solid") == 0) { - wwarning("Switch to solid"); - WMPerformButtonClick(panel->tsoliB); - - parseStringPosition = strtok(NULL,seperators); - - while (parseStringPosition) { - if (!strpbrk(parseStringPosition,enclosures)) { - WMSetColorWellColor(panel->scolorW,WMCreateNamedColor(WMWidgetScreen(panel->scolorW), parseStringPosition, True)); - } - parseStringPosition = strtok(NULL,seperators); - } + char *parseString; + char *parseStringPosition; + char *enclosures = "( )"; + char *seperators = " ,\""; + char *filename; + + WMSetButtonSelected(panel->tsoliB, False); + WMSetButtonSelected(panel->tgradB, False); + WMSetButtonSelected(panel->tpixmB, False); + + parseString = wstrdup(texture); + parseStringPosition = parseString; + + parseStringPosition = strtok(parseStringPosition,seperators); + wwarning ("Parsing..."); + + while (parseStringPosition) { - } else if ((strstr(parseStringPosition,"pixmap")) && (strcasecmp(strstr(parseStringPosition,"pixmap"),"pixmap") == 0)) { - WMSetButtonSelected(panel->ptileB, False); - WMSetButtonSelected(panel->pscalB, False); - - WMPerformButtonClick(panel->tpixmB); - - if (tolower(*parseStringPosition) == 't') { - wwarning ("Switch to Tiled Pixmap"); - WMPerformButtonClick(panel->ptileB); - } else { - wwarning ("Switch to Scaled Pixmap"); - WMPerformButtonClick(panel->pscalB); + if (!strpbrk(parseStringPosition,enclosures)) { + if (strcasecmp(parseStringPosition,"solid") == 0) { + wwarning("Switch to solid"); + WMPerformButtonClick(panel->tsoliB); + + parseStringPosition = strtok(NULL,seperators); + + while (parseStringPosition) { + if (!strpbrk(parseStringPosition,enclosures)) { + WMSetColorWellColor(panel->scolorW,WMCreateNamedColor(WMWidgetScreen(panel->scolorW), parseStringPosition, True)); + } + parseStringPosition = strtok(NULL,seperators); + } + + } else if ((strstr(parseStringPosition,"pixmap")) && (strcasecmp(strstr(parseStringPosition,"pixmap"),"pixmap") == 0)) { + WMSetButtonSelected(panel->ptileB, False); + WMSetButtonSelected(panel->pscalB, False); + + WMPerformButtonClick(panel->tpixmB); + + if (tolower(*parseStringPosition) == 't') { + wwarning ("Switch to Tiled Pixmap"); + WMPerformButtonClick(panel->ptileB); + } else { + wwarning ("Switch to Scaled Pixmap"); + WMPerformButtonClick(panel->pscalB); + } + + + filename = NULL; + parseStringPosition = strtok(NULL,seperators); + do { + if (filename) filename = wstrappend(filename," "); + filename = wstrappend(filename,parseStringPosition); + parseStringPosition = strtok(NULL,seperators); + } while (!strstr(parseStringPosition,"rgb:")); + + WMSetTextFieldText(panel->pimagT, filename); + free(filename); + + /* parseStringPosition = strtok(NULL,seperators); */ + + WMSetColorWellColor(panel->pcolorW,WMCreateNamedColor(WMWidgetScreen(panel->scolorW), parseStringPosition, True)); + + } else if ((strstr(parseStringPosition,"gradient")) && (strcasecmp(strstr(parseStringPosition,"gradient"),"gradient") == 0)) { + WMSetButtonSelected(panel->ghorB, False); + WMSetButtonSelected(panel->gverB, False); + WMSetButtonSelected(panel->gdiaB, False); + + WMPerformButtonClick(panel->tgradB); + + if (strstr(parseStringPosition,"h")) { + WMPerformButtonClick(panel->ghorB); + } else if (strstr(parseStringPosition,"v")) { + WMPerformButtonClick(panel->gverB); + } else { + WMPerformButtonClick(panel->gdiaB); + } + + WMClearList(panel->gcolorLs); + + parseStringPosition = strtok(NULL,seperators); + while (parseStringPosition) { + if (!strpbrk(parseStringPosition,enclosures)) { + WMAddListItem(panel->gcolorLs, parseStringPosition); + WMSetColorWellColor(panel->gcolorW,WMCreateNamedColor(WMWidgetScreen(panel->scolorW), parseStringPosition, True)); + } + parseStringPosition = strtok(NULL,seperators); + } + } else { + wfatal("Unknown Texture Type"); + } + + while (parseStringPosition) { + parseStringPosition = strtok(NULL,seperators); + } + } - - - filename = NULL; - parseStringPosition = strtok(NULL,seperators); - do { - if (filename) filename = wstrappend(filename," "); - filename = wstrappend(filename,parseStringPosition); - parseStringPosition = strtok(NULL,seperators); - } while (!strstr(parseStringPosition,"rgb:")); - - WMSetTextFieldText(panel->pimagT, filename); - free(filename); - - /* parseStringPosition = strtok(NULL,seperators); */ - - WMSetColorWellColor(panel->pcolorW,WMCreateNamedColor(WMWidgetScreen(panel->scolorW), parseStringPosition, True)); - - } else if ((strstr(parseStringPosition,"gradient")) && (strcasecmp(strstr(parseStringPosition,"gradient"),"gradient") == 0)) { - WMSetButtonSelected(panel->ghorB, False); - WMSetButtonSelected(panel->gverB, False); - WMSetButtonSelected(panel->gdiaB, False); - - WMPerformButtonClick(panel->tgradB); - - if (strstr(parseStringPosition,"h")) { - WMPerformButtonClick(panel->ghorB); - } else if (strstr(parseStringPosition,"v")) { - WMPerformButtonClick(panel->gverB); - } else { - WMPerformButtonClick(panel->gdiaB); - } - - WMClearList(panel->gcolorLs); - - parseStringPosition = strtok(NULL,seperators); - while (parseStringPosition) { - if (!strpbrk(parseStringPosition,enclosures)) { - WMAddListItem(panel->gcolorLs, parseStringPosition); - WMSetColorWellColor(panel->gcolorW,WMCreateNamedColor(WMWidgetScreen(panel->scolorW), parseStringPosition, True)); - } - parseStringPosition = strtok(NULL,seperators); - } - } else { - wfatal("Unknown Texture Type"); - } - - while (parseStringPosition) { - parseStringPosition = strtok(NULL,seperators); - } - - } - - parseStringPosition = strtok(NULL,seperators); + + parseStringPosition = strtok(NULL,seperators); } renderTextureButtons (panel); free(parseString); @@ -544,138 +546,138 @@ SetTexturePanelTexture(TexturePanel *panel, char *texture) char* GetTexturePanelTextureString(TexturePanel *panel) { - char *colorString = NULL; - char *start = "( "; - char *finish = " )"; - char *seperator = ", "; - char *quote = "\""; - int i, listRows; - - colorString = wstrappend(colorString,start); - - if (WMGetButtonSelected(panel->tsoliB)) { - colorString = wstrappend(colorString,"solid"); - colorString = wstrappend(colorString,seperator); - colorString = wstrappend(colorString, quote); - colorString = wstrappend(colorString,WMGetColorWellRGBString(panel->scolorW)); - colorString = wstrappend(colorString, quote); - - } else if (WMGetButtonSelected(panel->tgradB)) { - listRows = WMGetListNumberOfRows(panel->gcolorLs); + char *colorString = NULL; + char *start = "( "; + char *finish = " )"; + char *seperator = ", "; + char *quote = "\""; + int i, listRows; - if (listRows > 2) { - colorString = wstrappend(colorString,"m"); - } - if (WMGetButtonSelected(panel->ghorB)) { - colorString = wstrappend(colorString,"hgradient"); - } else if (WMGetButtonSelected(panel->gverB)) { - colorString = wstrappend(colorString,"vgradient"); - } else { - colorString = wstrappend(colorString,"dgradient"); - } + colorString = wstrappend(colorString,start); - for (i=0; i < listRows; i++) { - colorString = wstrappend(colorString, seperator); - colorString = wstrappend(colorString, quote); - colorString = wstrappend(colorString, wstrdup(WMGetListItem(panel->gcolorLs, i)->text)); - colorString = wstrappend(colorString, quote); - } - } else if (WMGetButtonSelected(panel->tpixmB)) { - if (WMGetButtonSelected(panel->pscalB)) { - colorString = wstrappend(colorString,"spixmap"); - } else { - colorString = wstrappend(colorString,"tpixmap"); + if (WMGetButtonSelected(panel->tsoliB)) { + colorString = wstrappend(colorString,"solid"); + colorString = wstrappend(colorString,seperator); + colorString = wstrappend(colorString, quote); + colorString = wstrappend(colorString,WMGetColorWellRGBString(panel->scolorW)); + colorString = wstrappend(colorString, quote); + + } else if (WMGetButtonSelected(panel->tgradB)) { + listRows = WMGetListNumberOfRows(panel->gcolorLs); + + if (listRows > 2) { + colorString = wstrappend(colorString,"m"); + } + if (WMGetButtonSelected(panel->ghorB)) { + colorString = wstrappend(colorString,"hgradient"); + } else if (WMGetButtonSelected(panel->gverB)) { + colorString = wstrappend(colorString,"vgradient"); + } else { + colorString = wstrappend(colorString,"dgradient"); + } + + for (i=0; i < listRows; i++) { + colorString = wstrappend(colorString, seperator); + colorString = wstrappend(colorString, quote); + colorString = wstrappend(colorString, wstrdup(WMGetListItem(panel->gcolorLs, i)->text)); + colorString = wstrappend(colorString, quote); + } + } else if (WMGetButtonSelected(panel->tpixmB)) { + if (WMGetButtonSelected(panel->pscalB)) { + colorString = wstrappend(colorString,"spixmap"); + } else { + colorString = wstrappend(colorString,"tpixmap"); + } + colorString = wstrappend(colorString,seperator); + colorString = wstrappend(colorString, WMGetTextFieldText(panel->pimagT)); + colorString = wstrappend(colorString,seperator); + colorString = wstrappend(colorString, quote); + colorString = wstrappend(colorString, WMGetColorWellRGBString(panel->pcolorW)); + colorString = wstrappend(colorString, quote); } - colorString = wstrappend(colorString,seperator); - colorString = wstrappend(colorString, WMGetTextFieldText(panel->pimagT)); - colorString = wstrappend(colorString,seperator); - colorString = wstrappend(colorString, quote); - colorString = wstrappend(colorString, WMGetColorWellRGBString(panel->pcolorW)); - colorString = wstrappend(colorString, quote); - } - - colorString = wstrappend(colorString,finish); - - return colorString; + + colorString = wstrappend(colorString,finish); + + return colorString; } RImage* RenderTexturePanelTexture(TexturePanel *panel, unsigned width, unsigned height) { - XColor color; - RContext *ctx; - RColor solidColor; - RColor **colors = NULL; - RImage *image=NULL, *fileImage; - WMScreen *scr; - WMColor *wellColor; - - int i, listRows, style; - - scr = WMWidgetScreen(panel->gcolorLs); - ctx = WMScreenRContext(scr); - - if (WMGetButtonSelected(panel->tsoliB)) { - - image = RCreateImage(width, height, 1); - wellColor = WMGetColorWellColor(panel->scolorW); - - solidColor.red = (WMRedComponentOfColor(wellColor) >> 8); - solidColor.green = (WMGreenComponentOfColor(wellColor) >> 8) ; - solidColor.blue = (WMBlueComponentOfColor(wellColor) >> 8); - solidColor.alpha = 0xff; - - WMReleaseColor(wellColor); - - RClearImage(image, &solidColor); + XColor color; + RContext *ctx; + RColor solidColor; + RColor **colors = NULL; + RImage *image=NULL, *fileImage; + WMScreen *scr; + WMColor *wellColor; - } else if (WMGetButtonSelected(panel->tgradB)) { + int i, listRows, style; - if (WMGetButtonSelected(panel->ghorB)) { - style = RGRD_HORIZONTAL; - } else if (WMGetButtonSelected(panel->gverB)) { - style = RGRD_VERTICAL; - } else { - style = RGRD_DIAGONAL; - } - - listRows = WMGetListNumberOfRows(panel->gcolorLs); - colors = wmalloc(sizeof(RColor*)*(listRows+1)); + scr = WMWidgetScreen(panel->gcolorLs); + ctx = WMScreenRContext(scr); - for (i=0; i < listRows; i++) { - if (!XParseColor(WMScreenDisplay(scr), ctx->cmap, - wstrdup(WMGetListItem(panel->gcolorLs, i)->text),&color)) { - wfatal("could not parse color \"%s\"\n", WMGetListItem(panel->gcolorLs, i)->text); - exit(1); - } else { - colors[i] = malloc(sizeof(RColor)); - colors[i]->red = color.red >> 8; - colors[i]->green = color.green >> 8; - colors[i]->blue = color.blue >> 8; - } + if (WMGetButtonSelected(panel->tsoliB)) { + + image = RCreateImage(width, height, 1); + wellColor = WMGetColorWellColor(panel->scolorW); + + solidColor.red = (WMRedComponentOfColor(wellColor) >> 8); + solidColor.green = (WMGreenComponentOfColor(wellColor) >> 8) ; + solidColor.blue = (WMBlueComponentOfColor(wellColor) >> 8); + solidColor.alpha = 0xff; + + WMReleaseColor(wellColor); + + RClearImage(image, &solidColor); + + } else if (WMGetButtonSelected(panel->tgradB)) { + + if (WMGetButtonSelected(panel->ghorB)) { + style = RGRD_HORIZONTAL; + } else if (WMGetButtonSelected(panel->gverB)) { + style = RGRD_VERTICAL; + } else { + style = RGRD_DIAGONAL; + } + + listRows = WMGetListNumberOfRows(panel->gcolorLs); + colors = wmalloc(sizeof(RColor*)*(listRows+1)); + + for (i=0; i < listRows; i++) { + if (!XParseColor(WMScreenDisplay(scr), ctx->cmap, + wstrdup(WMGetListItem(panel->gcolorLs, i)->text),&color)) { + wfatal("could not parse color \"%s\"\n", WMGetListItem(panel->gcolorLs, i)->text); + exit(1); + } else { + colors[i] = malloc(sizeof(RColor)); + colors[i]->red = color.red >> 8; + colors[i]->green = color.green >> 8; + colors[i]->blue = color.blue >> 8; + } + } + colors[i] = NULL; + + image = RRenderMultiGradient(width, height, colors, style); + + } else if (WMGetButtonSelected(panel->tpixmB)) { + + if (fopen(WMGetTextFieldText(panel->pimagT),"r")) { + + fileImage = RLoadImage(ctx, WMGetTextFieldText(panel->pimagT), 0); + if (WMGetButtonSelected(panel->pscalB)) { + image = RScaleImage(fileImage, width, height); + } else { + image = RMakeTiledImage(fileImage, width, height);; + } + } else { + wwarning ("Invalid File Name"); + return RCreateImage(1,1,1); + } } - colors[i] = NULL; - image = RRenderMultiGradient(width, height, colors, style); - - } else if (WMGetButtonSelected(panel->tpixmB)) { - - if (fopen(WMGetTextFieldText(panel->pimagT),"r")) { - - fileImage = RLoadImage(ctx, WMGetTextFieldText(panel->pimagT), 0); - if (WMGetButtonSelected(panel->pscalB)) { - image = RScaleImage(fileImage, width, height); - } else { - image = RMakeTiledImage(fileImage, width, height);; - } - } else { - wwarning ("Invalid File Name"); - return RCreateImage(1,1,1); - } - } - - return image; + return image; } TexturePanel* @@ -686,17 +688,17 @@ CreateTexturePanel(WMScreen *scr) WMColor *red; TexturePanel *panel; RColor white,black; - + white.red=255; white.blue=255; white.green=255; white.alpha=255; - + black.red=0; black.blue=0; black.green=0; black.alpha=0; - + panel = wmalloc(sizeof(_TexturePanel)); memset(panel, 0, sizeof(_TexturePanel)); red = WMCreateRGBColor(scr,100,100,100,True); @@ -704,14 +706,14 @@ CreateTexturePanel(WMScreen *scr) panel->win = WMCreateWindow(scr, "textureBuilder"); WMResizeWidget(panel->win, 275, 365); WMSetWindowTitle(panel->win, "Texture Builder"); - + /***************** Generic stuff ****************/ panel->typeF = WMCreateFrame(panel->win); WMResizeWidget(panel->typeF, 245, 80); WMMoveWidget(panel->typeF, 15, 10); WMSetFrameTitle(panel->typeF, "Texture Type"); - + panel->tsoliB = WMCreateButton(panel->typeF, WBTOnOff); WMResizeWidget(panel->tsoliB, 48, 48); WMMoveWidget(panel->tsoliB, 42, 20); @@ -758,13 +760,13 @@ CreateTexturePanel(WMScreen *scr) WMReleasePixmap(icon); } WMSetButtonAction(panel->tpixmB, buttonCallback, panel); - + panel->okB = WMCreateCommandButton(panel->win); WMResizeWidget(panel->okB, 70, 28); WMMoveWidget(panel->okB, 110, 325); WMSetButtonText(panel->okB, "OK"); WMSetButtonAction(panel->okB,buttonCallback,panel); - + panel->cancB = WMCreateCommandButton(panel->win); WMResizeWidget(panel->cancB, 70, 28); WMMoveWidget(panel->cancB, 190, 325); @@ -783,7 +785,7 @@ CreateTexturePanel(WMScreen *scr) WMResizeWidget(panel->scolorW, 60, 45); WMMoveWidget(panel->scolorW, 95, 40); WMSetColorWellColor(panel->scolorW,WMCreateRGBColor(scr, 0xddff, 0xddff, 0, True)); - + WMMapSubwidgets(panel->scolorF); /***************** Gradient *****************/ @@ -795,9 +797,9 @@ CreateTexturePanel(WMScreen *scr) panel->gcolorLs = WMCreateList(panel->gcolorF); WMResizeWidget(panel->gcolorLs, 120, 84); WMMoveWidget(panel->gcolorLs, 20, 20); - + WMSetListUserDrawProc(panel->gcolorLs, paintListItem); - + WMAddListItem(panel->gcolorLs, "rgb:ff/ff/ff"); WMAddListItem(panel->gcolorLs, "rgb:00/00/ff"); @@ -811,13 +813,13 @@ CreateTexturePanel(WMScreen *scr) WMMoveWidget(panel->gremB, 20, 110); WMSetButtonText(panel->gremB, "Remove"); WMSetButtonAction(panel->gremB,(WMAction*)buttonCallback,panel); - + panel->gupdB = WMCreateCommandButton(panel->gcolorF); WMResizeWidget(panel->gupdB, 64, 24); WMMoveWidget(panel->gupdB, 90, 110); WMSetButtonText(panel->gupdB, "Update"); WMSetButtonAction(panel->gupdB,(WMAction*)buttonCallback,panel); - + panel->gaddB = WMCreateCommandButton(panel->gcolorF); WMResizeWidget(panel->gaddB, 64, 24); WMMoveWidget(panel->gaddB, 160, 110); @@ -835,14 +837,14 @@ CreateTexturePanel(WMScreen *scr) WMMoveWidget(panel->ghorB, 20, 20); WMSetButtonImagePosition(panel->ghorB, WIPImageOnly); WMPerformButtonClick(panel->ghorB); - - + + panel->gverB = WMCreateButton(panel->gdirF, WBTOnOff); WMResizeWidget(panel->gverB, 64, 34); WMMoveWidget(panel->gverB, 90, 20); WMSetButtonImagePosition(panel->gverB, WIPImageOnly); WMGroupButtons(panel->ghorB, panel->gverB); - + panel->gdiaB = WMCreateButton(panel->gdirF, WBTOnOff); WMResizeWidget(panel->gdiaB, 64, 34); WMMoveWidget(panel->gdiaB, 160, 20); @@ -856,7 +858,7 @@ CreateTexturePanel(WMScreen *scr) WMResizeWidget(panel->pimagF, 245, 140); WMMoveWidget(panel->pimagF, 15, 96); WMSetFrameTitle(panel->pimagF, "Image"); - + panel->pimagL = WMCreateLabel(panel->pimagF); WMResizeWidget(panel->pimagL, 220, 83); WMMoveWidget(panel->pimagL, 10, 20); @@ -865,25 +867,25 @@ CreateTexturePanel(WMScreen *scr) panel->pimagT = WMCreateTextField(panel->pimagF); WMResizeWidget(panel->pimagT, 147, 20); WMMoveWidget(panel->pimagT, 10, 110); - + panel->pbrowB = WMCreateCommandButton(panel->pimagF); WMResizeWidget(panel->pbrowB, 68, 24); WMMoveWidget(panel->pbrowB, 165, 108); WMSetButtonText(panel->pbrowB, "Browse..."); WMSetButtonAction(panel->pbrowB,buttonCallback,panel); - + WMMapSubwidgets(panel->pimagF); - + panel->pcolorF = WMCreateFrame(panel->win); WMResizeWidget(panel->pcolorF, 90, 75); WMMoveWidget(panel->pcolorF, 15, 240); WMSetFrameTitle(panel->pcolorF, "Color"); - + panel->pcolorW = WMCreateColorWell(panel->pcolorF); WMResizeWidget(panel->pcolorW, 60, 45); WMMoveWidget(panel->pcolorW, 15, 20); WMSetColorWellColor(panel->pcolorW,WMCreateRGBColor(scr, 0x00, 0xddff, 0xffff, True)); - + WMMapSubwidgets(panel->pcolorF); @@ -896,7 +898,7 @@ CreateTexturePanel(WMScreen *scr) WMMoveWidget(panel->pscalB, 10, 10); WMSetButtonImagePosition(panel->pscalB, WIPImageOnly); WMPerformButtonClick(panel->pscalB); - + image = RGetImageFromXPMData(WMScreenRContext(scr), scaled_xpm); if (!image) { wwarning("internal error:%s", RMessageForError(RErrorCode)); @@ -906,7 +908,7 @@ CreateTexturePanel(WMScreen *scr) WMSetButtonImage(panel->pscalB, icon); WMReleasePixmap(icon); } - + panel->ptileB = WMCreateButton(panel->pmodeF, WBTOnOff); WMResizeWidget(panel->ptileB, 54, 50); WMMoveWidget(panel->ptileB, 75, 10); @@ -921,24 +923,24 @@ CreateTexturePanel(WMScreen *scr) WMReleasePixmap(icon); } WMGroupButtons(panel->pscalB, panel->ptileB); - + WMMapSubwidgets(panel->pmodeF); WMRealizeWidget(panel->win); WMMapSubwidgets(panel->win); - + WMPerformButtonClick(panel->tsoliB); - + WMMapWidget(panel->win); renderTextureButtons (panel); - - + + /* register notification observers */ WMAddNotificationObserver(notificationObserver, panel, WMTextDidChangeNotification, panel->pimagT); - + return panel; } @@ -955,71 +957,71 @@ CreateTexturePanel(WMScreen *scr) char *ProgName = "test"; void testOKButton(WMWidget *self, void *data){ - char *test; - Display *dpy; - Window win; - Pixmap pix; - RImage *image; - - TexturePanel *panel = (TexturePanel*)data; - test = GetTexturePanelTextureString(panel); - - wwarning(test); - - dpy = WMScreenDisplay(WMWidgetScreen(panel->okB)); - win = XCreateSimpleWindow(dpy, DefaultRootWindow(dpy), 10, 10, 250, 250, - 0, 0, 0); - XMapRaised(dpy, win); - XFlush(dpy); - - image = RenderTexturePanelTexture(panel, 250, 250); - - RConvertImage(WMScreenRContext(WMWidgetScreen(panel->okB)), image, &pix); - - XCopyArea(dpy, pix, win, (WMScreenRContext(WMWidgetScreen(panel->okB)))->copy_gc, 0, 0, image->width, image->height, - 0, 0); - - SetTexturePanelTexture(panel, test); - free (test); - + char *test; + Display *dpy; + Window win; + Pixmap pix; + RImage *image; + + TexturePanel *panel = (TexturePanel*)data; + test = GetTexturePanelTextureString(panel); + + wwarning(test); + + dpy = WMScreenDisplay(WMWidgetScreen(panel->okB)); + win = XCreateSimpleWindow(dpy, DefaultRootWindow(dpy), 10, 10, 250, 250, + 0, 0, 0); + XMapRaised(dpy, win); + XFlush(dpy); + + image = RenderTexturePanelTexture(panel, 250, 250); + + RConvertImage(WMScreenRContext(WMWidgetScreen(panel->okB)), image, &pix); + + XCopyArea(dpy, pix, win, (WMScreenRContext(WMWidgetScreen(panel->okB)))->copy_gc, 0, 0, image->width, image->height, + 0, 0); + + SetTexturePanelTexture(panel, test); + free (test); + } void testCancelButton(WMWidget *self, void *data){ - wwarning("Exiting test...."); - exit(0); + wwarning("Exiting test...."); + exit(0); } void wAbort() { -exit(1); + exit(1); } int main(int argc, char **argv) { TexturePanel *panel; - + Display *dpy = XOpenDisplay(""); WMScreen *scr; - + /* char *test; */ - + WMInitializeApplication("Test", &argc, argv); - + if (!dpy) { wfatal("could not open display"); exit(1); } scr = WMCreateSimpleApplicationScreen(dpy); - + panel = CreateTexturePanel(scr); - + SetTexturePanelOkAction(panel,(WMAction*)testOKButton,panel); SetTexturePanelCancelAction(panel,(WMAction*)testCancelButton,panel); - + ShowTexturePanel(panel); - + SetTexturePanelTexture(panel," ( tpixmap, ballot box.xpm, \"rgb:ff/de/ff\" ) "); - + WMScreenMainLoop(scr); return 0; } diff --git a/WPrefs.app/WPrefs.c b/WPrefs.app/WPrefs.c index 9f900775..fec14e11 100644 --- a/WPrefs.app/WPrefs.c +++ b/WPrefs.app/WPrefs.c @@ -55,8 +55,6 @@ extern Panel *InitIcons(WMScreen *scr, WMWindow *win); extern Panel *InitThemes(WMScreen *scr, WMWindow *win); -extern Panel *InitTextureAndColor(WMScreen *scr, WMWindow *win); - extern Panel *InitAppearance(WMScreen *scr, WMWindow *win); @@ -373,32 +371,20 @@ LocateImage(char *name) void -AddSection(Panel *panel, char *iconFile) +SetButtonAlphaImage(WMScreen *scr, WMButton *bPtr, char *file) { - WMButton *bPtr; WMPixmap *icon; RColor color; char *iconPath; - assert(WPrefs.sectionCount < MAX_SECTIONS); - - iconPath = LocateImage(iconFile); - - bPtr = WMCreateCustomButton(WPrefs.buttonF, WBBStateLightMask - |WBBStateChangeMask); - WMResizeWidget(bPtr, 64, 64); - WMMoveWidget(bPtr, WPrefs.sectionCount*64, 0); - WMSetButtonImagePosition(bPtr, WIPImageOnly); - WMSetButtonAction(bPtr, changeSection, panel); - WMHangData(bPtr, panel); + iconPath = LocateImage(file); color.red = 0xae; color.green = 0xaa; color.blue = 0xae; color.alpha = 0; if (iconPath) { - icon = WMCreateBlendedPixmapFromFile(WMWidgetScreen(WPrefs.win), - iconPath, &color); + icon = WMCreateBlendedPixmapFromFile(scr, iconPath, &color); if (!icon) wwarning(_("could not load icon file %s"), iconPath); } else { @@ -415,8 +401,7 @@ AddSection(Panel *panel, char *iconFile) color.blue = 0xff; color.alpha = 0; if (iconPath) { - icon = WMCreateBlendedPixmapFromFile(WMWidgetScreen(WPrefs.win), - iconPath, &color); + icon = WMCreateBlendedPixmapFromFile(scr, iconPath, &color); if (!icon) wwarning(_("could not load icon file %s"), iconPath); } else { @@ -428,6 +413,29 @@ AddSection(Panel *panel, char *iconFile) if (icon) WMReleasePixmap(icon); + if (iconPath) + free(iconPath); +} + + +void +AddSection(Panel *panel, char *iconFile) +{ + WMButton *bPtr; + + assert(WPrefs.sectionCount < MAX_SECTIONS); + + + bPtr = WMCreateCustomButton(WPrefs.buttonF, WBBStateLightMask + |WBBStateChangeMask); + WMResizeWidget(bPtr, 64, 64); + WMMoveWidget(bPtr, WPrefs.sectionCount*64, 0); + WMSetButtonImagePosition(bPtr, WIPImageOnly); + WMSetButtonAction(bPtr, changeSection, panel); + WMHangData(bPtr, panel); + + SetButtonAlphaImage(WMWidgetScreen(bPtr), bPtr, iconFile); + WMMapWidget(bPtr); WPrefs.sectionB[WPrefs.sectionCount] = bPtr; @@ -439,8 +447,6 @@ AddSection(Panel *panel, char *iconFile) WPrefs.sectionCount++; WMResizeWidget(WPrefs.buttonF, WPrefs.sectionCount*64, 64); - - free(iconPath); } @@ -494,7 +500,7 @@ Initialize(WMScreen *scr) loadConfigurations(scr, WPrefs.win); WMSetLabelText(WPrefs.statusL, _("Initializing configuration panels...")); -#if 1 + InitWindowHandling(scr, WPrefs.win); InitFocus(scr, WPrefs.win); InitMenuPreferences(scr, WPrefs.win); @@ -504,22 +510,22 @@ Initialize(WMScreen *scr) InitPaths(scr, WPrefs.win); InitWorkspace(scr, WPrefs.win); InitConfigurations(scr, WPrefs.win); -#endif + InitMenu(scr, WPrefs.win); -#if 1 + #ifdef not_yet_fully_implemented InitKeyboardSettings(scr, WPrefs.win); #endif InitKeyboardShortcuts(scr, WPrefs.win); InitMouseSettings(scr, WPrefs.win); - #ifdef not_yet_fully_implemented InitAppearance(scr, WPrefs.win); + InitText(scr, WPrefs.win); InitThemes(scr, WPrefs.win); #endif InitExpert(scr, WPrefs.win); -#endif + WMRealizeWidget(WPrefs.scrollV); WMSetLabelText(WPrefs.statusL, diff --git a/WPrefs.app/WPrefs.h b/WPrefs.app/WPrefs.h index 35a245dc..6df8bc05 100644 --- a/WPrefs.app/WPrefs.h +++ b/WPrefs.app/WPrefs.h @@ -42,7 +42,7 @@ /****/ -#define WVERSION "0.11" +#define WVERSION "0.20" #define WMVERSION "0.51.x" @@ -73,6 +73,8 @@ void AddSection(Panel *panel, char *iconFile); char *LocateImage(char *name); +void SetButtonAlphaImage(WMScreen *scr, WMButton *bPtr, char *file); + WMWindow *GetWindow(Panel *panel); /* manipulate the dictionary for the WindowMaker domain */ diff --git a/WPrefs.app/WindowHandling.c b/WPrefs.app/WindowHandling.c index d7c10174..ce8ebe52 100644 --- a/WPrefs.app/WindowHandling.c +++ b/WPrefs.app/WindowHandling.c @@ -223,7 +223,7 @@ createPanel(Panel *p) WMSetFrameTitle(panel->placF, _("Window Placement")); panel->placP = WMCreatePopUpButton(panel->placF); - WMResizeWidget(panel->placP, 120, 20); + WMResizeWidget(panel->placP, 105, 20); WMMoveWidget(panel->placP, 15, 20); WMAddPopUpButtonItem(panel->placP, _("Automatic")); WMAddPopUpButtonItem(panel->placP, _("Random")); @@ -231,7 +231,7 @@ createPanel(Panel *p) WMAddPopUpButtonItem(panel->placP, _("Cascade")); panel->porigL = WMCreateLabel(panel->placF); - WMResizeWidget(panel->porigL, 138, 32); + WMResizeWidget(panel->porigL, 120, 32); WMMoveWidget(panel->porigL, 5, 45); WMSetLabelTextAlignment(panel->porigL, WACenter); WMSetLabelText(panel->porigL, _("Placement Origin")); @@ -250,15 +250,21 @@ createPanel(Panel *p) swidth = WidthOfScreen(DefaultScreenOfDisplay(WMScreenDisplay(scr))); sheight = HeightOfScreen(DefaultScreenOfDisplay(WMScreenDisplay(scr))); - if (120*sheight/swidth < 70*swidth/sheight) { - width = 70*swidth/sheight; + if (sheight > swidth) { height = 70; + width = 70*swidth/sheight; + if (width > 115) + width = 115; + height = 115*sheight/swidth; } else { - height = 120*sheight/swidth; - width = 120; + width = 115; + height = 115*sheight/swidth; + if (height > 70) + height = 70; + width = 70*swidth/sheight; } WMResizeWidget(panel->porigF, width, height); - WMMoveWidget(panel->porigF, 135+(120-width)/2, 20+(70-height)/2); + WMMoveWidget(panel->porigF, 130+(115-width)/2, 20+(70-height)/2); panel->porigW = WMCreateLabel(panel->porigF); WMResizeWidget(panel->porigW, THUMB_SIZE, THUMB_SIZE); @@ -268,14 +274,14 @@ createPanel(Panel *p) panel->hsli = WMCreateSlider(panel->placF); WMResizeWidget(panel->hsli, width, 12); - WMMoveWidget(panel->hsli, 135+(120-width)/2, 20+(70-height)/2+height+2); + WMMoveWidget(panel->hsli, 130+(115-width)/2, 20+(70-height)/2+height+2); WMSetSliderAction(panel->hsli, sliderCallback, panel); WMSetSliderMinValue(panel->hsli, 0); WMSetSliderMaxValue(panel->hsli, swidth); panel->vsli = WMCreateSlider(panel->placF); WMResizeWidget(panel->vsli, 12, height); - WMMoveWidget(panel->vsli, 135+(120-width)/2+width+2, 20+(70-height)/2); + WMMoveWidget(panel->vsli, 130+(115-width)/2+width+2, 20+(70-height)/2); WMSetSliderAction(panel->vsli, sliderCallback, panel); WMSetSliderMinValue(panel->vsli, 0); WMSetSliderMaxValue(panel->vsli, sheight); diff --git a/WPrefs.app/double.c b/WPrefs.app/double.c index b4da7034..0053bfac 100644 --- a/WPrefs.app/double.c +++ b/WPrefs.app/double.c @@ -105,7 +105,7 @@ paintDoubleTest(_DoubleTest *dPtr) W_Screen *scr = dPtr->view->screen; if (dPtr->active) { - XFillRectangle(scr->display, dPtr->view->window, W_GC(scr->white), + XFillRectangle(scr->display, dPtr->view->window, WMColorGC(scr->white), 0, 0, dPtr->view->size.width, dPtr->view->size.height); } else { XClearWindow(scr->display, dPtr->view->window); @@ -119,7 +119,7 @@ paintDoubleTest(_DoubleTest *dPtr) y = (dPtr->view->size.height-scr->normalFont->height)/2; W_PaintText(dPtr->view, dPtr->view->window, scr->normalFont, dPtr->on, dPtr->on+y, dPtr->view->size.width, WACenter, - W_GC(scr->black), False, dPtr->text, strlen(dPtr->text)); + WMColorGC(scr->black), False, dPtr->text, strlen(dPtr->text)); } } diff --git a/WPrefs.app/editmenu.c b/WPrefs.app/editmenu.c index 1fe5d112..039ac611 100644 --- a/WPrefs.app/editmenu.c +++ b/WPrefs.app/editmenu.c @@ -150,7 +150,7 @@ paintEditMenuItem(WEditMenuItem *iPtr) W_DrawRelief(scr, win, 0, 0, w+1, h, WRRaised); - WMDrawString(scr, win, W_GC(black), scr->normalFont, 5, 3, iPtr->label, + WMDrawString(scr, win, WMColorGC(black), scr->normalFont, 5, 3, iPtr->label, strlen(iPtr->label)); } @@ -366,7 +366,7 @@ WInsertMenuItemWithTitle(WEditMenu *mPtr, char *title, int index) index = mPtr->itemCount; if (mPtr->itemCount == mPtr->itemsAlloced) { - WEditMenuItem **newList; + WEditMenuItem *newList; newList = wmalloc(sizeof(WEditMenuItem*)*(mPtr->itemsAlloced+10)); memset(newList, 0, sizeof(WEditMenuItem*)*(mPtr->itemsAlloced+10)); @@ -458,11 +458,11 @@ paintMenuTitle(WEditMenu *mPtr) int w = W_VIEW(mPtr)->size.width; int h = mPtr->titleHeight; - XFillRectangle(scr->display, win, W_GC(black), 0, 0, w, h); + XFillRectangle(scr->display, win, WMColorGC(black), 0, 0, w, h); W_DrawRelief(scr, win, 0, 0, w+1, h, WRRaised); - WMDrawString(scr, win, W_GC(white), scr->boldFont, 5, 4, mPtr->label, + WMDrawString(scr, win, WMColorGC(white), scr->boldFont, 5, 4, mPtr->label, strlen(mPtr->label)); } diff --git a/WPrefs.app/main.c b/WPrefs.app/main.c index fc7e8870..18ec706a 100644 --- a/WPrefs.app/main.c +++ b/WPrefs.app/main.c @@ -165,7 +165,7 @@ main(int argc, char **argv) wfatal(_("could not open display %s"), XDisplayName(display_name)); exit(0); } -#if 1 +#if 0 XSynchronize(dpy, 1); #endif scr = WMCreateScreen(dpy, DefaultScreen(dpy)); diff --git a/WPrefs.app/po/Makefile.am b/WPrefs.app/po/Makefile.am index 3c4b5af6..199d1f83 100644 --- a/WPrefs.app/po/Makefile.am +++ b/WPrefs.app/po/Makefile.am @@ -1,6 +1,6 @@ CATALOGS = @WPMOFILES@ -nlsdir = $(DESTDIR)$(NLSDIR) +nlsdir = $(NLSDIR) CLEANFILES = $(CATALOGS) diff --git a/WPrefs.app/po/Makefile.in b/WPrefs.app/po/Makefile.in index ef43f81e..9f3f4ff7 100644 --- a/WPrefs.app/po/Makefile.in +++ b/WPrefs.app/po/Makefile.in @@ -89,7 +89,7 @@ wprefsdir = @wprefsdir@ CATALOGS = @WPMOFILES@ -nlsdir = $(DESTDIR)$(NLSDIR) +nlsdir = $(NLSDIR) CLEANFILES = $(CATALOGS) diff --git a/WindowMaker/Defaults/WindowMaker b/WindowMaker/Defaults/WindowMaker index 85365819..d0fbecfd 100755 --- a/WindowMaker/Defaults/WindowMaker +++ b/WindowMaker/Defaults/WindowMaker @@ -1,6 +1,6 @@ { OpenTransientOnOwnerWorkspace = NO; - EdgeResistance = YES; + EdgeResistance = 30; IconificationStyle = Zoom; IconPath = ( "~/GNUstep/Library/Icons", @@ -48,7 +48,6 @@ AutoArrangeIcons = NO; AdvanceToNewWorkspace = NO; CycleWorkspaces = NO; - WindozeCycling = NO; ResizeDisplay = line; MoveDisplay = floating; OpaqueMove = YES; diff --git a/WindowMaker/Defaults/WindowMaker.in b/WindowMaker/Defaults/WindowMaker.in index 5e52b81e..a85195dc 100644 --- a/WindowMaker/Defaults/WindowMaker.in +++ b/WindowMaker/Defaults/WindowMaker.in @@ -1,6 +1,6 @@ { OpenTransientOnOwnerWorkspace = NO; - EdgeResistance = YES; + EdgeResistance = 30; IconificationStyle = Zoom; IconPath = ( "~/GNUstep/Library/Icons", @@ -48,7 +48,6 @@ AutoArrangeIcons = NO; AdvanceToNewWorkspace = NO; CycleWorkspaces = NO; - WindozeCycling = NO; ResizeDisplay = line; MoveDisplay = floating; OpaqueMove = YES; diff --git a/WindowMaker/Themes/Makefile.am b/WindowMaker/Themes/Makefile.am index ae0b2fec..d083f889 100644 --- a/WindowMaker/Themes/Makefile.am +++ b/WindowMaker/Themes/Makefile.am @@ -1,4 +1,4 @@ -SUBDIRS = Night.themed Checker.themed +SUBDIRS = Night.themed Checker.themed LeetWM.themed STEP2000.themed defsdatadir = $(pkgdatadir)/Themes diff --git a/WindowMaker/Themes/Makefile.in b/WindowMaker/Themes/Makefile.in index 41e9ac44..309aedb8 100755 --- a/WindowMaker/Themes/Makefile.in +++ b/WindowMaker/Themes/Makefile.in @@ -87,7 +87,7 @@ XLIBS = @XLIBS@ X_EXTRA_LIBS = @X_EXTRA_LIBS@ wprefsdir = @wprefsdir@ -SUBDIRS = Night.themed Checker.themed +SUBDIRS = Night.themed Checker.themed LeetWM.themed STEP2000.themed defsdatadir = $(pkgdatadir)/Themes @@ -104,7 +104,7 @@ DIST_COMMON = Makefile.am Makefile.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best all: all-redirect .SUFFIXES: diff --git a/WindowMaker/Themes/Night.themed/Makefile.in b/WindowMaker/Themes/Night.themed/Makefile.in index 238a07e9..c590c0e9 100755 --- a/WindowMaker/Themes/Night.themed/Makefile.in +++ b/WindowMaker/Themes/Night.themed/Makefile.in @@ -103,7 +103,7 @@ DIST_COMMON = Makefile.am Makefile.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best all: all-redirect .SUFFIXES: diff --git a/WindowMaker/Themes/STEP2000.themed/BlueImage2.jpeg b/WindowMaker/Themes/STEP2000.themed/BlueImage2.jpeg new file mode 100755 index 0000000000000000000000000000000000000000..5fd8c699169f59e95017b9e9aa287af72718176a GIT binary patch literal 45024 zcwVHrcTf{f`2U$0dJ{w-NYMBph*aq$0s<-}AVG>CRg?}Uq|lobMTLM6nvxKd-cfoN zL`pycQUyYhDkUJGAR=;p?{0qg&&}M;-LwDgKC?Tot?&2j$(NIP0Kc&T(f|Mi0sz2& z1#t2gV0*(tU(d?S;wtp6HPqS-Pw?`^Kvfi!6z@Z!7H$Dop-ReElo3}Ds?f`~QHD_L zeLojZsFH%RG!$y?fB&JEUocb~s-&nW2em}|`ucf#VLbj-C~}=l18)2q=>K2*PbdFR zIscDw(hd;d0IUI}LBRh2rv!i?0pQ6;z=eNP!1{kA0RGPao&vG3vaxe;a&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1P_`q zZ0>6b{6W5SsoZ}>=mKy_==b&6 to continue." -read blabla +AC_MSG_WARN([The problems above may or may not cause Window Maker +not to install or run properly. If you have any problems during +installation or execution, please resolve the problems and try to +install Window Maker again.]) +echo +fi else echo -echo "None of the RedHat problems known to this script were found." +echo "You appear to have a system packaged by Red Hat, but I could" +echo "not find any Red-Hat-specific problems that I know about." echo fi fi diff --git a/aclocal.m4 b/aclocal.m4 index fa3d2b9d..dbb17dde 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -18,7 +18,7 @@ dnl AC_DEFUN(WM_CHECK_LIB, [ LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" AC_CHECK_LIB([$1],[$2],yes=yes,no=no,[$3]) LDFLAGS="$LDFLAGS_old" ]) @@ -43,8 +43,10 @@ AC_DEFUN(WM_CHECK_REDCRAP_BUGS, [ AC_MSG_CHECKING(for RedHat system) wm_check_flag='no :)' +rh_is_redhat=no if test -f /etc/redhat-release; then wm_check_flag=yes + rh_is_redhat=yes fi AC_MSG_RESULT($wm_check_flag) @@ -52,10 +54,7 @@ mins_found=no bugs_found=no if test "$wm_check_flag" = yes; then echo -AC_MSG_WARN([it seems you are using a system packaged by RedHat. -I will now do some checks for RedHat specific bugs. If some check -fail, please read the INSTALL file regarding RedHat, resolve the -problem and retry to configure.]) +AC_MSG_WARN([Red Hat system; checking for Red-Hat-specific bugs.]) echo # # Check old wmaker from RedHat @@ -64,12 +63,10 @@ if test "[$1]" != "/usr/X11R6" -a "$prefix" != "/usr/X11"; then AC_MSG_CHECKING(for multiple installed wmaker versions) if test -f /usr/X11R6/bin/wmaker; then AC_MSG_RESULT(uh oh) -AC_MSG_WARN([you seem to have an old version of Window Maker -installed at /usr/X11R6/bin. It is recommended that you uninstall -any previously installed packages of WindowMaker before installing -a new one.]) mins_found=yes +rh_old_wmaker=yes else +rh_old_wmaker=no AC_MSG_RESULT(no apparent problems) fi fi @@ -96,19 +93,19 @@ fi if test "[$2]" = "/usr/local/bin"; then AC_MSG_CHECKING(if /usr/local/bin is in the search PATH) wm_check_flag=no +rh_missing_usr_local_bin=yes old_IFS="$IFS" IFS=":" for i in $PATH; do if test "x$i" = "x/usr/local/bin"; then wm_check_flag=yes + rh_missing_usr_local_bin=no break; fi done IFS="$old_IFS" if test "$wm_check_flag" = no; then AC_MSG_RESULT(uh oh) -AC_MSG_WARN([/usr/local/bin is not in the PATH environment variable. -Please resolve the problem.]) bugs_found=yes else AC_MSG_RESULT(no problem) @@ -120,13 +117,13 @@ fi # if test "[$3]" = "/usr/local/lib"; then wm_check_flag=yes +rh_missing_usr_local_lib=no AC_MSG_CHECKING(if /usr/local/lib is in /etc/ld.so.conf) test -z "`grep /usr/local/lib /etc/ld.so.conf`" test "$?" -eq 0 && wm_check_flag=no if test "$wm_check_flag" = no; then AC_MSG_RESULT(uh oh) -AC_MSG_WARN([/usr/local/lib is not in the /etc/ld.so.conf file. -Please add it there.]) +rh_missing_usr_local_lib=yes bugs_found=yes else AC_MSG_RESULT(no problem) @@ -136,20 +133,21 @@ fi # Check for symbolic links # AC_MSG_CHECKING(for /usr/X11 symbolic link) +rh_missing_usr_x11=no if test -d "/usr/X11"; then AC_MSG_RESULT(found) else AC_MSG_RESULT(uh oh) -AC_MSG_WARN([Please create a symbolic link from /usr/X11R6 to /usr/X11.]) +rh_missing_usr_x11=yes mins_found=yes fi AC_MSG_CHECKING(for /usr/include/X11 symbolic link) +rh_missing_usr_include_x11=no if test -d "/usr/include/X11"; then AC_MSG_RESULT(found) else AC_MSG_RESULT(uh oh) -AC_MSG_WARN([Please create a symbolic link from /usr/X11R6/include/X11 -to /usr/include/X11.]) +rh_missing_usr_include_x11=yes mins_found=yes fi @@ -157,30 +155,91 @@ fi # Check for /lib/cpp # AC_MSG_CHECKING(for /lib/cpp) +rh_missing_lib_cpp=no if test -f "/lib/cpp"; then AC_MSG_RESULT(found) else AC_MSG_RESULT(uh oh) -AC_MSG_WARN([Please create a symbolic link from the cpp (C preprocessor) -program to /lib/cpp]) +rh_missing_lib_cpp=yes bugs_found=yes fi +echo +fi +]) + + +dnl +dnl WM_PRINT_REDCRAP_BUG_STATUS() +dnl +AC_DEFUN(WM_PRINT_REDCRAP_BUG_STATUS, +[ +if test "$rh_is_redhat" = yes; then +if test "$mins_found" = yes -o "$bugs_found" = yes; then +echo +AC_MSG_WARN([It seems you are using a system packaged by Red Hat. +I have done some checks for Red-Hat-specific bugs, and I found some +problems. Please read the INSTALL file regarding Red Hat, resolve +the problems, and try to run configure again. + +Here are the problems I found: +]) +if test "x$rh_old_wmaker" = xyes; then +echo "Problem: Old version of Window Maker in /usr/X11R6/bin." +echo "Description: You seem to have an old version of Window Maker" +echo " installed in /usr/X11R6/bin. It is recommended" +echo " that you uninstall any previously installed" +echo " packages of WindowMaker before installing a new one." +echo +fi +if test "x$rh_missing_usr_local_bin" = xyes; then +echo "Problem: PATH is missing /usr/local/bin." +echo "Description: Your PATH environment variable does not appear to" +echo " contain the directory /usr/local/bin. Please add it." +echo +fi +if test "x$rh_missing_usr_local_lib" = xyes; then +echo "Problem: /etc/ld.so.conf missing /usr/local/lib" +echo "Description: Your /etc/ld.so.conf file does not appear to contain" +echo " the directory /usr/local/lib. Please add it." +echo +fi +if test "x$rh_missing_usr_x11" = xyes; then +echo "Problem: Missing /usr/X11 symbolic link." +echo "Description: Your system is missing a symbolic link from" +echo " /usr/X11R6 to /usr/X11. Please create one." +echo +fi +if test "x$rh_missing_usr_include_x11" = xyes; then +echo "Problem: Missing /usr/include/X11 symbolic link." +echo "Description: Your system is missing a symbolic link from" +echo " /usr/X11R6/include/X11 to /usr/include/X11." +echo " Please create one." +echo +fi +if test "x$rh_missing_lib_cpp" = xyes; then +echo "Problem: Missing /lib/cpp symbolic link." +echo "Description: Your system is missing a symbolic link from the" +echo " cpp (C preprocessor) program to /lib/cpp." +echo " Please create one." +echo +fi if test "x$bugs_found" = xyes; then -AC_MSG_ERROR([Some bugs that can potentially cause problems during -installation/execution were found. Please correct these problems -and retry later.]) +AC_MSG_ERROR([One or more of the problems above can potentially +cause Window Maker not to install or run properly. Please resolve +the problems and try to run configure again.]) exit 1 elif test "x$mins_found" = xyes; then -AC_MSG_WARN([Some minor problems that might or might not cause -problems were found. If you have any problems during -installation/execution, please resolve the pointed problems and try -to reinstall.]) -echo "Press to continue." -read blabla +AC_MSG_WARN([The problems above may or may not cause Window Maker +not to install or run properly. If you have any problems during +installation or execution, please resolve the problems and try to +install Window Maker again.]) +echo +fi else echo -echo "None of the RedHat problems known to this script were found." +echo "You appear to have a system packaged by Red Hat, but I could" +echo "not find any Red-Hat-specific problems that I know about." echo fi fi diff --git a/configure b/configure index 954c0ceb..06da9ea9 100755 --- a/configure +++ b/configure @@ -751,7 +751,7 @@ fi PACKAGE=WindowMaker -VERSION=0.51.1 +VERSION=0.51.2 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; } @@ -1813,8 +1813,10 @@ inc_search_path="-I`eval echo $inc_search_path`" echo $ac_n "checking for RedHat system""... $ac_c" 1>&6 echo "configure:1815: checking for RedHat system" >&5 wm_check_flag='no :)' +rh_is_redhat=no if test -f /etc/redhat-release; then wm_check_flag=yes + rh_is_redhat=yes fi echo "$ac_t""$wm_check_flag" 1>&6 @@ -1822,25 +1824,20 @@ mins_found=no bugs_found=no if test "$wm_check_flag" = yes; then echo -echo "configure: warning: it seems you are using a system packaged by RedHat. -I will now do some checks for RedHat specific bugs. If some check -fail, please read the INSTALL file regarding RedHat, resolve the -problem and retry to configure." 1>&2 +echo "configure: warning: Red Hat system; checking for Red-Hat-specific bugs." 1>&2 echo # # Check old wmaker from RedHat # if test "$prefix" != "/usr/X11R6" -a "$prefix" != "/usr/X11"; then echo $ac_n "checking for multiple installed wmaker versions""... $ac_c" 1>&6 -echo "configure:1836: checking for multiple installed wmaker versions" >&5 +echo "configure:1835: checking for multiple installed wmaker versions" >&5 if test -f /usr/X11R6/bin/wmaker; then echo "$ac_t""uh oh" 1>&6 -echo "configure: warning: you seem to have an old version of Window Maker -installed at /usr/X11R6/bin. It is recommended that you uninstall -any previously installed packages of WindowMaker before installing -a new one." 1>&2 mins_found=yes +rh_old_wmaker=yes else +rh_old_wmaker=no echo "$ac_t""no apparent problems" 1>&6 fi fi @@ -1866,21 +1863,21 @@ fi # if test "$_bindir" = "/usr/local/bin"; then echo $ac_n "checking if /usr/local/bin is in the search PATH""... $ac_c" 1>&6 -echo "configure:1870: checking if /usr/local/bin is in the search PATH" >&5 +echo "configure:1867: checking if /usr/local/bin is in the search PATH" >&5 wm_check_flag=no +rh_missing_usr_local_bin=yes old_IFS="$IFS" IFS=":" for i in $PATH; do if test "x$i" = "x/usr/local/bin"; then wm_check_flag=yes + rh_missing_usr_local_bin=no break; fi done IFS="$old_IFS" if test "$wm_check_flag" = no; then echo "$ac_t""uh oh" 1>&6 -echo "configure: warning: /usr/local/bin is not in the PATH environment variable. -Please resolve the problem." 1>&2 bugs_found=yes else echo "$ac_t""no problem" 1>&6 @@ -1892,14 +1889,14 @@ fi # if test "$_libdir" = "/usr/local/lib"; then wm_check_flag=yes +rh_missing_usr_local_lib=no echo $ac_n "checking if /usr/local/lib is in /etc/ld.so.conf""... $ac_c" 1>&6 -echo "configure:1897: checking if /usr/local/lib is in /etc/ld.so.conf" >&5 +echo "configure:1895: checking if /usr/local/lib is in /etc/ld.so.conf" >&5 test -z "`grep /usr/local/lib /etc/ld.so.conf`" test "$?" -eq 0 && wm_check_flag=no if test "$wm_check_flag" = no; then echo "$ac_t""uh oh" 1>&6 -echo "configure: warning: /usr/local/lib is not in the /etc/ld.so.conf file. -Please add it there." 1>&2 +rh_missing_usr_local_lib=yes bugs_found=yes else echo "$ac_t""no problem" 1>&6 @@ -1909,22 +1906,23 @@ fi # Check for symbolic links # echo $ac_n "checking for /usr/X11 symbolic link""... $ac_c" 1>&6 -echo "configure:1913: checking for /usr/X11 symbolic link" >&5 +echo "configure:1910: checking for /usr/X11 symbolic link" >&5 +rh_missing_usr_x11=no if test -d "/usr/X11"; then echo "$ac_t""found" 1>&6 else echo "$ac_t""uh oh" 1>&6 -echo "configure: warning: Please create a symbolic link from /usr/X11R6 to /usr/X11." 1>&2 +rh_missing_usr_x11=yes mins_found=yes fi echo $ac_n "checking for /usr/include/X11 symbolic link""... $ac_c" 1>&6 -echo "configure:1922: checking for /usr/include/X11 symbolic link" >&5 +echo "configure:1920: checking for /usr/include/X11 symbolic link" >&5 +rh_missing_usr_include_x11=no if test -d "/usr/include/X11"; then echo "$ac_t""found" 1>&6 else echo "$ac_t""uh oh" 1>&6 -echo "configure: warning: Please create a symbolic link from /usr/X11R6/include/X11 -to /usr/include/X11." 1>&2 +rh_missing_usr_include_x11=yes mins_found=yes fi @@ -1932,34 +1930,18 @@ fi # Check for /lib/cpp # echo $ac_n "checking for /lib/cpp""... $ac_c" 1>&6 -echo "configure:1936: checking for /lib/cpp" >&5 +echo "configure:1934: checking for /lib/cpp" >&5 +rh_missing_lib_cpp=no if test -f "/lib/cpp"; then echo "$ac_t""found" 1>&6 else echo "$ac_t""uh oh" 1>&6 -echo "configure: warning: Please create a symbolic link from the cpp (C preprocessor) -program to /lib/cpp" 1>&2 +rh_missing_lib_cpp=yes bugs_found=yes fi -if test "x$bugs_found" = xyes; then -{ echo "configure: error: Some bugs that can potentially cause problems during -installation/execution were found. Please correct these problems -and retry later." 1>&2; exit 1; } -exit 1 -elif test "x$mins_found" = xyes; then -echo "configure: warning: Some minor problems that might or might not cause -problems were found. If you have any problems during -installation/execution, please resolve the pointed problems and try -to reinstall." 1>&2 -echo "Press to continue." -read blabla -else -echo -echo "None of the RedHat problems known to this script were found." echo fi -fi @@ -1980,12 +1962,12 @@ fi echo $ac_n "checking for vprintf""... $ac_c" 1>&6 -echo "configure:1984: checking for vprintf" >&5 +echo "configure:1966: checking for vprintf" >&5 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:1994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_vprintf=yes" else @@ -2032,12 +2014,12 @@ fi if test "$ac_cv_func_vprintf" != yes; then echo $ac_n "checking for _doprnt""... $ac_c" 1>&6 -echo "configure:2036: checking for _doprnt" >&5 +echo "configure:2018: checking for _doprnt" >&5 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2046: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func__doprnt=yes" else @@ -2087,19 +2069,19 @@ fi # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6 -echo "configure:2091: checking for working alloca.h" >&5 +echo "configure:2073: checking for working alloca.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < int main() { char *p = alloca(2 * sizeof(int)); ; return 0; } EOF -if { (eval echo configure:2103: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2085: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_header_alloca_h=yes else @@ -2120,12 +2102,12 @@ EOF fi echo $ac_n "checking for alloca""... $ac_c" 1>&6 -echo "configure:2124: checking for alloca" >&5 +echo "configure:2106: checking for alloca" >&5 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2139: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_cv_func_alloca_works=yes else @@ -2185,12 +2167,12 @@ EOF echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6 -echo "configure:2189: checking whether alloca needs Cray hooks" >&5 +echo "configure:2171: checking whether alloca needs Cray hooks" >&5 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&6 if test $ac_cv_os_cray = yes; then for ac_func in _getb67 GETB67 getb67; do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2219: checking for $ac_func" >&5 +echo "configure:2201: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2229: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2270,7 +2252,7 @@ done fi echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6 -echo "configure:2274: checking stack direction for C alloca" >&5 +echo "configure:2256: checking stack direction for C alloca" >&5 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2278,7 +2260,7 @@ else ac_cv_c_stack_direction=0 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2283: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_c_stack_direction=1 else @@ -2321,12 +2303,12 @@ fi for ac_func in gethostname select poll strerror strncasecmp setpgid atexit do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2325: checking for $ac_func" >&5 +echo "configure:2307: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2378,7 +2360,7 @@ if test "x$CPP_PATH" = x; then # Extract the first word of "cpp", so it can be a program name with args. set dummy cpp; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2382: checking for $ac_word" >&5 +echo "configure:2364: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_path_CPP_PATH'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2391,7 +2373,7 @@ else ;; *) IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" - ac_dummy="/lib:/usr/bin:/bin:/usr/lib:/usr/ccs/lib:$PATH" + ac_dummy="$PATH:/lib:/usr/bin:/bin:/usr/lib:/usr/ccs/lib" for ac_dir in $ac_dummy; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$ac_word; then @@ -2434,12 +2416,12 @@ EOF echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6 -echo "configure:2438: checking for sys/wait.h that is POSIX.1 compatible" >&5 +echo "configure:2420: checking for sys/wait.h that is POSIX.1 compatible" >&5 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -2455,7 +2437,7 @@ wait (&s); s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; ; return 0; } EOF -if { (eval echo configure:2459: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2441: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_sys_wait_h=yes else @@ -2476,12 +2458,12 @@ EOF fi echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 -echo "configure:2480: checking whether time.h and sys/time.h may both be included" >&5 +echo "configure:2462: checking whether time.h and sys/time.h may both be included" >&5 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -2490,7 +2472,7 @@ int main() { struct tm *tp; ; return 0; } EOF -if { (eval echo configure:2494: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2476: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_header_time=yes else @@ -2515,17 +2497,17 @@ for ac_hdr in fcntl.h limits.h sys/ioctl.h sys/time.h sys/types.h\ do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:2519: checking for $ac_hdr" >&5 +echo "configure:2501: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:2529: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:2511: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -2555,12 +2537,12 @@ done echo $ac_n "checking for sys_siglist declaration in signal.h or unistd.h""... $ac_c" 1>&6 -echo "configure:2559: checking for sys_siglist declaration in signal.h or unistd.h" >&5 +echo "configure:2541: checking for sys_siglist declaration in signal.h or unistd.h" >&5 if eval "test \"`echo '$''{'ac_cv_decl_sys_siglist'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -2572,7 +2554,7 @@ int main() { char *msg = *(sys_siglist + 1); ; return 0; } EOF -if { (eval echo configure:2576: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2558: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_decl_sys_siglist=yes else @@ -2593,12 +2575,12 @@ EOF fi echo $ac_n "checking for working const""... $ac_c" 1>&6 -echo "configure:2597: checking for working const" >&5 +echo "configure:2579: checking for working const" >&5 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2633: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_const=yes else @@ -2670,12 +2652,12 @@ fi #AC_TYPE_SIZE_T #AC_TYPE_PID_T echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6 -echo "configure:2674: checking return type of signal handlers" >&5 +echo "configure:2656: checking return type of signal handlers" >&5 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -2692,7 +2674,7 @@ int main() { int i; ; return 0; } EOF -if { (eval echo configure:2696: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:2678: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_type_signal=void else @@ -2721,12 +2703,12 @@ INTLIBS="" echo $ac_n "checking for gettext""... $ac_c" 1>&6 -echo "configure:2725: checking for gettext" >&5 +echo "configure:2707: checking for gettext" >&5 if eval "test \"`echo '$''{'ac_cv_func_gettext'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2735: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_gettext=yes" else @@ -2767,7 +2749,7 @@ if eval "test \"`echo '$ac_cv_func_'gettext`\" = yes"; then else echo "$ac_t""no" 1>&6 echo $ac_n "checking for gettext in -lintl""... $ac_c" 1>&6 -echo "configure:2771: checking for gettext in -lintl" >&5 +echo "configure:2753: checking for gettext in -lintl" >&5 ac_lib_var=`echo intl'_'gettext | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2775,7 +2757,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lintl $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -2813,7 +2795,7 @@ fi # Extract the first word of "xgettext", so it can be a program name with args. set dummy xgettext; ac_word=$2 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 -echo "configure:2817: checking for $ac_word" >&5 +echo "configure:2799: checking for $ac_word" >&5 if eval "test \"`echo '$''{'ac_cv_prog_XGETTEXT'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2919,7 +2901,7 @@ if test "$enable_kanji" = yes; then case $host_os in freebsd*) echo $ac_n "checking for setlocale in -lxpg4""... $ac_c" 1>&6 -echo "configure:2923: checking for setlocale in -lxpg4" >&5 +echo "configure:2905: checking for setlocale in -lxpg4" >&5 ac_lib_var=`echo xpg4'_'setlocale | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -2927,7 +2909,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lxpg4 $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2924: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3058,7 +3040,7 @@ fi # Uses ac_ vars as temps to allow command line to override cache and checks. # --without-x overrides everything else, but does not touch the cache. echo $ac_n "checking for X""... $ac_c" 1>&6 -echo "configure:3062: checking for X" >&5 +echo "configure:3044: checking for X" >&5 # Check whether --with-x or --without-x was given. if test "${with_x+set}" = set; then @@ -3120,12 +3102,12 @@ if test "$ac_x_includes" = NO; then # First, try using that file with no special directory specified. cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:3129: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:3111: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -3194,14 +3176,14 @@ if test "$ac_x_libraries" = NO; then ac_save_LIBS="$LIBS" LIBS="-l$x_direct_test_library $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3187: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* LIBS="$ac_save_LIBS" # We can link X programs with no special library path. @@ -3307,17 +3289,17 @@ else case "`(uname -sr) 2>/dev/null`" in "SunOS 5"*) echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6 -echo "configure:3311: checking whether -R must be followed by a space" >&5 +echo "configure:3293: checking whether -R must be followed by a space" >&5 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_R_nospace=yes else @@ -3333,14 +3315,14 @@ rm -f conftest* else LIBS="$ac_xsave_LIBS -R $x_libraries" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* ac_R_space=yes else @@ -3372,7 +3354,7 @@ rm -f conftest* # libraries were built with DECnet support. And karl@cs.umb.edu says # the Alpha needs dnet_stub (dnet does not exist). echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6 -echo "configure:3376: checking for dnet_ntoa in -ldnet" >&5 +echo "configure:3358: checking for dnet_ntoa in -ldnet" >&5 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3380,7 +3362,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldnet $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3413,7 +3395,7 @@ fi if test $ac_cv_lib_dnet_dnet_ntoa = no; then echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6 -echo "configure:3417: checking for dnet_ntoa in -ldnet_stub" >&5 +echo "configure:3399: checking for dnet_ntoa in -ldnet_stub" >&5 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3421,7 +3403,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ldnet_stub $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3418: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3461,12 +3443,12 @@ fi # The nsl library prevents programs from opening the X display # on Irix 5.2, according to dickey@clark.net. echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 -echo "configure:3465: checking for gethostbyname" >&5 +echo "configure:3447: checking for gethostbyname" >&5 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_gethostbyname=yes" else @@ -3510,7 +3492,7 @@ fi if test $ac_cv_func_gethostbyname = no; then echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 -echo "configure:3514: checking for gethostbyname in -lnsl" >&5 +echo "configure:3496: checking for gethostbyname in -lnsl" >&5 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3518,7 +3500,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lnsl $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3515: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3559,12 +3541,12 @@ fi # -lsocket must be given before -lnsl if both are needed. # We assume that if connect needs -lnsl, so does gethostbyname. echo $ac_n "checking for connect""... $ac_c" 1>&6 -echo "configure:3563: checking for connect" >&5 +echo "configure:3545: checking for connect" >&5 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_connect=yes" else @@ -3608,7 +3590,7 @@ fi if test $ac_cv_func_connect = no; then echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6 -echo "configure:3612: checking for connect in -lsocket" >&5 +echo "configure:3594: checking for connect in -lsocket" >&5 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3616,7 +3598,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lsocket $X_EXTRA_LIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3613: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3651,12 +3633,12 @@ fi # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX. echo $ac_n "checking for remove""... $ac_c" 1>&6 -echo "configure:3655: checking for remove" >&5 +echo "configure:3637: checking for remove" >&5 if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3665: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_remove=yes" else @@ -3700,7 +3682,7 @@ fi if test $ac_cv_func_remove = no; then echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6 -echo "configure:3704: checking for remove in -lposix" >&5 +echo "configure:3686: checking for remove in -lposix" >&5 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3708,7 +3690,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lposix $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3705: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3743,12 +3725,12 @@ fi # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. echo $ac_n "checking for shmat""... $ac_c" 1>&6 -echo "configure:3747: checking for shmat" >&5 +echo "configure:3729: checking for shmat" >&5 if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3757: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_shmat=yes" else @@ -3792,7 +3774,7 @@ fi if test $ac_cv_func_shmat = no; then echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6 -echo "configure:3796: checking for shmat in -lipc" >&5 +echo "configure:3778: checking for shmat in -lipc" >&5 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3800,7 +3782,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lipc $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3797: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3844,7 +3826,7 @@ fi # libraries we check for below, so use a different variable. # --interran@uluru.Stanford.EDU, kb@cs.umb.edu. echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6 -echo "configure:3848: checking for IceConnectionNumber in -lICE" >&5 +echo "configure:3830: checking for IceConnectionNumber in -lICE" >&5 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3852,7 +3834,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lICE $X_EXTRA_LIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3849: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3909,7 +3891,7 @@ fi if test "$use_locale" = yes; then echo $ac_n "checking for _Xsetlocale in -lX11""... $ac_c" 1>&6 -echo "configure:3913: checking for _Xsetlocale in -lX11" >&5 +echo "configure:3895: checking for _Xsetlocale in -lX11" >&5 ac_lib_var=`echo X11'_'_Xsetlocale | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3917,7 +3899,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lX11 $XLFLAGS $XLIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3914: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -3977,7 +3959,7 @@ added_xext=no if test "$shape" = yes; then echo $ac_n "checking for XShapeSelectInput in -lXext""... $ac_c" 1>&6 -echo "configure:3981: checking for XShapeSelectInput in -lXext" >&5 +echo "configure:3963: checking for XShapeSelectInput in -lXext" >&5 ac_lib_var=`echo Xext'_'XShapeSelectInput | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -3985,7 +3967,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lXext $XLFLAGS $XLIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:3982: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4037,7 +4019,7 @@ fi if test "$shm" = yes; then echo $ac_n "checking for XShmAttach in -lXext""... $ac_c" 1>&6 -echo "configure:4041: checking for XShmAttach in -lXext" >&5 +echo "configure:4023: checking for XShmAttach in -lXext" >&5 ac_lib_var=`echo Xext'_'XShmAttach | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4045,7 +4027,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lXext $XLFLAGS $XLIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4080,12 +4062,12 @@ fi if test "$ok" = yes; then echo $ac_n "checking for shmget""... $ac_c" 1>&6 -echo "configure:4084: checking for shmget" >&5 +echo "configure:4066: checking for shmget" >&5 if eval "test \"`echo '$''{'ac_cv_func_shmget'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4094: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_shmget=yes" else @@ -4155,9 +4137,9 @@ LIBPL="" LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for PLGetString in -lPropList""... $ac_c" 1>&6 -echo "configure:4161: checking for PLGetString in -lPropList" >&5 +echo "configure:4143: checking for PLGetString in -lPropList" >&5 ac_lib_var=`echo PropList'_'PLGetString | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4165,7 +4147,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lPropList $X_EXTRA_LIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4162: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4205,17 +4187,17 @@ CPPFLAGS_old="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $inc_search_path" ac_safe=`echo "proplist.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for proplist.h""... $ac_c" 1>&6 -echo "configure:4209: checking for proplist.h" >&5 +echo "configure:4191: checking for proplist.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4219: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4201: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4281,9 +4263,9 @@ fi if test "$xpm" = yes; then LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for XpmCreatePixmapFromData in -lXpm""... $ac_c" 1>&6 -echo "configure:4287: checking for XpmCreatePixmapFromData in -lXpm" >&5 +echo "configure:4269: checking for XpmCreatePixmapFromData in -lXpm" >&5 ac_lib_var=`echo Xpm'_'XpmCreatePixmapFromData | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4291,7 +4273,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lXpm $XLFLAGS $XLIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4288: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4332,17 +4314,17 @@ CPPFLAGS_old="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $inc_search_path" ac_safe=`echo "X11/xpm.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for X11/xpm.h""... $ac_c" 1>&6 -echo "configure:4336: checking for X11/xpm.h" >&5 +echo "configure:4318: checking for X11/xpm.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4346: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4328: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4402,9 +4384,9 @@ fi if test "$png" = yes ; then LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for png_get_valid in -lpng""... $ac_c" 1>&6 -echo "configure:4408: checking for png_get_valid in -lpng" >&5 +echo "configure:4390: checking for png_get_valid in -lpng" >&5 ac_lib_var=`echo png'_'png_get_valid | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4412,7 +4394,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lpng -lz -lm $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4409: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4453,17 +4435,17 @@ CPPFLAGS_old="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $inc_search_path" ac_safe=`echo "png.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for png.h""... $ac_c" 1>&6 -echo "configure:4457: checking for png.h" >&5 +echo "configure:4439: checking for png.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4467: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4449: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4511,9 +4493,9 @@ fi if test "$jpeg" = yes; then LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for jpeg_destroy_compress in -ljpeg""... $ac_c" 1>&6 -echo "configure:4517: checking for jpeg_destroy_compress in -ljpeg" >&5 +echo "configure:4499: checking for jpeg_destroy_compress in -ljpeg" >&5 ac_lib_var=`echo jpeg'_'jpeg_destroy_compress | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4521,7 +4503,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ljpeg $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4562,17 +4544,17 @@ CPPFLAGS_old="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $inc_search_path" ac_safe=`echo "jpeglib.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for jpeglib.h""... $ac_c" 1>&6 -echo "configure:4566: checking for jpeglib.h" >&5 +echo "configure:4548: checking for jpeglib.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4576: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4558: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4621,9 +4603,9 @@ if test "$gif" = yes; then my_libname="" LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for DGifOpenFileName in -lungif""... $ac_c" 1>&6 -echo "configure:4627: checking for DGifOpenFileName in -lungif" >&5 +echo "configure:4609: checking for DGifOpenFileName in -lungif" >&5 ac_lib_var=`echo ungif'_'DGifOpenFileName | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4631,7 +4613,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lungif $XLFLAGS $XLIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4628: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4671,9 +4653,9 @@ LDFLAGS="$LDFLAGS_old" if test "x$my_libname" = x; then LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for DGifOpenFileName in -lgif""... $ac_c" 1>&6 -echo "configure:4677: checking for DGifOpenFileName in -lgif" >&5 +echo "configure:4659: checking for DGifOpenFileName in -lgif" >&5 ac_lib_var=`echo gif'_'DGifOpenFileName | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4681,7 +4663,7 @@ else ac_save_LIBS="$LIBS" LIBS="-lgif $XLFLAGS $XLIBS $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4726,17 +4708,17 @@ CPPFLAGS_old="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $inc_search_path" ac_safe=`echo "gif_lib.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for gif_lib.h""... $ac_c" 1>&6 -echo "configure:4730: checking for gif_lib.h" >&5 +echo "configure:4712: checking for gif_lib.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:4740: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4722: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -4795,9 +4777,9 @@ if test "$tif" = yes; then my_libname="" LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for TIFFGetVersion in -ltiff""... $ac_c" 1>&6 -echo "configure:4801: checking for TIFFGetVersion in -ltiff" >&5 +echo "configure:4783: checking for TIFFGetVersion in -ltiff" >&5 ac_lib_var=`echo tiff'_'TIFFGetVersion | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4805,7 +4787,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ltiff -lm $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4802: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4846,9 +4828,9 @@ LDFLAGS="$LDFLAGS_old" if test "x$my_libname" = x; then LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for TIFFGetVersion in -ltiff""... $ac_c" 1>&6 -echo "configure:4852: checking for TIFFGetVersion in -ltiff" >&5 +echo "configure:4834: checking for TIFFGetVersion in -ltiff" >&5 ac_lib_var=`echo tiff'_'TIFFGetVersion | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4856,7 +4838,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ltiff -lz -lm $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4898,9 +4880,9 @@ LDFLAGS="$LDFLAGS_old" if test "x$my_libname" = x; then LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" +LDFLAGS="$LDFLAGS $lib_search_path" echo $ac_n "checking for TIFFGetVersion in -ltiff34""... $ac_c" 1>&6 -echo "configure:4904: checking for TIFFGetVersion in -ltiff34" >&5 +echo "configure:4886: checking for TIFFGetVersion in -ltiff34" >&5 ac_lib_var=`echo tiff34'_'TIFFGetVersion | sed 'y%./+-%__p_%'` if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 @@ -4908,7 +4890,7 @@ else ac_save_LIBS="$LIBS" LIBS="-ltiff34 -lm $LIBS" cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:4905: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_lib_$ac_lib_var=yes" else @@ -4947,60 +4929,6 @@ LDFLAGS="$LDFLAGS_old" fi fi -# -# why the heck does debian name libtiff this way!? -# - if test "x$my_libname" = x; then - -LDFLAGS_old="$LDFLAGS" -LDFLAGS="-DBEGIN $LDFLAGS -DEND $lib_search_path" -echo $ac_n "checking for TIFFGetVersion in -ltiff3g""... $ac_c" 1>&6 -echo "configure:4959: checking for TIFFGetVersion in -ltiff3g" >&5 -ac_lib_var=`echo tiff3g'_'TIFFGetVersion | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then - echo $ac_n "(cached) $ac_c" 1>&6 -else - ac_save_LIBS="$LIBS" -LIBS="-ltiff3g -lm $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" -else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" -fi -rm -f conftest* -LIBS="$ac_save_LIBS" - -fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - yes=yes -else - echo "$ac_t""no" 1>&6 -no=no -fi - -LDFLAGS="$LDFLAGS_old" - - if test "x$ac_cv_lib_tiff3g_TIFFGetVersion" = xyes; then - my_libname="-ltiff3g" - fi - fi if test "x$my_libname" != x; then @@ -5008,17 +4936,17 @@ CPPFLAGS_old="$CPPFLAGS" CPPFLAGS="$CPPFLAGS $inc_search_path" ac_safe=`echo "tiffio.h" | sed 'y%./+-%__p_%'` echo $ac_n "checking for tiffio.h""... $ac_c" 1>&6 -echo "configure:5012: checking for tiffio.h" >&5 +echo "configure:4940: checking for tiffio.h" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:5022: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:4950: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -5127,9 +5055,9 @@ cat >> confdefs.h <> confdefs.h <&2 +if test "x$rh_old_wmaker" = xyes; then +echo "Problem: Old version of Window Maker in /usr/X11R6/bin." +echo "Description: You seem to have an old version of Window Maker" +echo " installed in /usr/X11R6/bin. It is recommended" +echo " that you uninstall any previously installed" +echo " packages of WindowMaker before installing a new one." +echo +fi +if test "x$rh_missing_usr_local_bin" = xyes; then +echo "Problem: PATH is missing /usr/local/bin." +echo "Description: Your PATH environment variable does not appear to" +echo " contain the directory /usr/local/bin. Please add it." +echo +fi +if test "x$rh_missing_usr_local_lib" = xyes; then +echo "Problem: /etc/ld.so.conf missing /usr/local/lib" +echo "Description: Your /etc/ld.so.conf file does not appear to contain" +echo " the directory /usr/local/lib. Please add it." +echo +fi +if test "x$rh_missing_usr_x11" = xyes; then +echo "Problem: Missing /usr/X11 symbolic link." +echo "Description: Your system is missing a symbolic link from" +echo " /usr/X11R6 to /usr/X11. Please create one." +echo +fi +if test "x$rh_missing_usr_include_x11" = xyes; then +echo "Problem: Missing /usr/include/X11 symbolic link." +echo "Description: Your system is missing a symbolic link from" +echo " /usr/X11R6/include/X11 to /usr/include/X11." +echo " Please create one." +echo +fi +if test "x$rh_missing_lib_cpp" = xyes; then +echo "Problem: Missing /lib/cpp symbolic link." +echo "Description: Your system is missing a symbolic link from the" +echo " cpp (C preprocessor) program to /lib/cpp." +echo " Please create one." +echo +fi +if test "x$bugs_found" = xyes; then +{ echo "configure: error: One or more of the problems above can potentially +cause Window Maker not to install or run properly. Please resolve +the problems and try to run configure again." 1>&2; exit 1; } +exit 1 +elif test "x$mins_found" = xyes; then +echo "configure: warning: The problems above may or may not cause Window Maker +not to install or run properly. If you have any problems during +installation or execution, please resolve the problems and try to +install Window Maker again." 1>&2 +echo +fi +else +echo +echo "You appear to have a system packaged by Red Hat, but I could" +echo "not find any Red-Hat-specific problems that I know about." +echo +fi +fi + + if test "x$ac_cv_header_jpeglib_h" != xyes; then echo "WARNING WARNING WARNING WARNING WARNING WARNING WARNING" echo diff --git a/configure.in b/configure.in index b846dd23..efc8444f 100644 --- a/configure.in +++ b/configure.in @@ -10,7 +10,7 @@ AC_INIT(src/WindowMaker.h) -AM_INIT_AUTOMAKE(WindowMaker, 0.51.1) +AM_INIT_AUTOMAKE(WindowMaker, 0.51.2) AM_PROG_LIBTOOL @@ -100,7 +100,7 @@ AC_CHECK_FUNCS(gethostname select poll strerror strncasecmp setpgid atexit) if test "x$CPP_PATH" = x; then AC_PATH_PROG(CPP_PATH, cpp, notfound, - /lib:/usr/bin:/bin:/usr/lib:/usr/ccs/lib:$PATH) + $PATH:/lib:/usr/bin:/bin:/usr/lib:/usr/ccs/lib) fi dnl @@ -589,15 +589,6 @@ dnl fi fi -# -# why the heck does debian name libtiff this way!? -# - if test "x$my_libname" = x; then - WM_CHECK_LIB(tiff3g, TIFFGetVersion, [-lm]) - if test "x$ac_cv_lib_tiff3g_TIFFGetVersion" = xyes; then - my_libname="-ltiff3g" - fi - fi if test "x$my_libname" != x; then WM_CHECK_HEADER(tiffio.h) @@ -669,8 +660,8 @@ AC_DEFINE_UNQUOTED(PIXMAPDIR, "$pixmapdir") pkgdatadir=`eval echo $datadir` AC_DEFINE_UNQUOTED(PKGDATADIR, "$pkgdatadir/WindowMaker") -sysconfdir=`eval echo $sysconfdir` -AC_DEFINE_UNQUOTED(SYSCONFDIR, "$sysconfdir/WindowMaker") +_sysconfdir=`eval echo $sysconfdir` +AC_DEFINE_UNQUOTED(SYSCONFDIR, "$_sysconfdir/WindowMaker") dnl Support for GNUSTEP_LOCAL_ROOT, for WPrefs.app @@ -742,7 +733,9 @@ AC_OUTPUT(Makefile po/Makefile util/Makefile test/Makefile wmlib/Makefile \ WindowMaker/Pixmaps/Makefile WindowMaker/Styles/Makefile \ WindowMaker/Themes/Makefile \ WindowMaker/Themes/Night.themed/Makefile \ + WindowMaker/Themes/LeetWM.themed/Makefile \ WindowMaker/Themes/Checker.themed/Makefile \ + WindowMaker/Themes/STEP2000.themed/Makefile \ WPrefs.app/Makefile WPrefs.app/tiff/Makefile WPrefs.app/xpm/Makefile \ WPrefs.app/po/Makefile ) @@ -831,6 +824,7 @@ if test "x$MOFILES" != "x"; then echo "Installation path of translated messages: $NLSDIR" | sed -e 's|\$(prefix)|'"$prefix|" fi +WM_PRINT_REDCRAP_BUG_STATUS if test "x$ac_cv_header_jpeglib_h" != xyes; then echo "WARNING WARNING WARNING WARNING WARNING WARNING WARNING" diff --git a/doc/Makefile.in b/doc/Makefile.in index c9c51a56..07f1bc14 100644 --- a/doc/Makefile.in +++ b/doc/Makefile.in @@ -103,7 +103,7 @@ DIST_COMMON = Makefile.am Makefile.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best all: all-redirect .SUFFIXES: diff --git a/po/Makefile.am b/po/Makefile.am index e7bc6615..c7ed348e 100644 --- a/po/Makefile.am +++ b/po/Makefile.am @@ -1,4 +1,4 @@ -nlsdir = $(DESTDIR)$(NLSDIR) +nlsdir = $(NLSDIR) CATALOGS = @MOFILES@ diff --git a/po/Makefile.in b/po/Makefile.in index df2e118c..9a09cdce 100644 --- a/po/Makefile.in +++ b/po/Makefile.in @@ -87,7 +87,7 @@ XLIBS = @XLIBS@ X_EXTRA_LIBS = @X_EXTRA_LIBS@ wprefsdir = @wprefsdir@ -nlsdir = $(DESTDIR)$(NLSDIR) +nlsdir = $(NLSDIR) CATALOGS = @MOFILES@ @@ -113,7 +113,7 @@ DIST_COMMON = README Makefile.am Makefile.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best all: all-redirect .SUFFIXES: diff --git a/src/Makefile.in b/src/Makefile.in index f47d4b93..5f306861 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -139,7 +139,7 @@ wconfig.h.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best SOURCES = $(wmaker_SOURCES) OBJECTS = $(wmaker_OBJECTS) diff --git a/src/WindowMaker.h b/src/WindowMaker.h index 15a2b9ce..57f2cebe 100644 --- a/src/WindowMaker.h +++ b/src/WindowMaker.h @@ -200,6 +200,14 @@ typedef enum { #define WSTATE_NEED_RESTART 2 #define WSTATE_EXITING 3 #define WSTATE_RESTARTING 4 +#define WSTATE_MODAL 5 + + +#define WCHECK_STATE(state) (state == WProgramState) +#define WCHANGE_STATE(nstate) \ + if (WProgramState == WSTATE_NORMAL\ + || nstate != WSTATE_MODAL)\ + WProgramState = (nstate) typedef struct { @@ -352,6 +360,7 @@ typedef struct WPreferences { extern Display *dpy; extern char *ProgName; extern unsigned int ValidModMask; +extern char WProgramState; /****** Global Functions ******/ extern void wAbort(Bool dumpCore); diff --git a/src/actions.c b/src/actions.c index d889e047..5c584919 100644 --- a/src/actions.c +++ b/src/actions.c @@ -415,7 +415,15 @@ wMaximizeWindow(WWindow *wwin, int directions) if (WFLAGP(wwin, no_resizable)) return; + + if (WFLAGP(wwin, full_maximize)) { + usableArea.x1 = 0; + usableArea.y1 = 0; + usableArea.x2 = wwin->screen_ptr->scr_width; + usableArea.y2 = wwin->screen_ptr->scr_height; + } + if (wwin->flags.shaded) { wwin->flags.skip_next_animation = 1; wUnshadeWindow(wwin); @@ -446,6 +454,8 @@ wMaximizeWindow(WWindow *wwin, int directions) new_height = (usableArea.y2-usableArea.y1)-FRAME_BORDER_WIDTH*2; new_y = usableArea.y1; + if (WFLAGP(wwin, full_maximize)) + new_y -= wwin->frame->top_width; } else { @@ -453,7 +463,10 @@ wMaximizeWindow(WWindow *wwin, int directions) new_height = wwin->frame->core->height; } - new_height -= wwin->frame->top_width+wwin->frame->bottom_width; + + if (!WFLAGP(wwin, full_maximize)) { + new_height -= wwin->frame->top_width+wwin->frame->bottom_width; + } wWindowConstrainSize(wwin, &new_width, &new_height); wWindowConfigure(wwin, new_x, new_y, new_width, new_height); @@ -1012,10 +1025,11 @@ wDeiconifyWindow(WWindow *wwin) if (!wwin->flags.miniaturized) return; - if (wwin->transient_for != None) { + if (wwin->transient_for != None + && wwin->transient_for != wwin->screen_ptr->root_win) { WWindow *owner = recursiveTransientFor(wwin); - if (wwin->flags.miniaturized) { + if (owner && owner->flags.miniaturized) { wDeiconifyWindow(owner); wSetFocusTo(wwin->screen_ptr, wwin); wRaiseFrame(wwin->frame->core); diff --git a/src/appicon.c b/src/appicon.c index 8064370a..07dcc516 100644 --- a/src/appicon.c +++ b/src/appicon.c @@ -525,17 +525,32 @@ static void killCallback(WMenu *menu, WMenuEntry *entry) { WApplication *wapp = (WApplication*)entry->clientdata; + char *buffer; + + if (!WCHECK_STATE(WSTATE_NORMAL)) + return; + + WCHANGE_STATE(WSTATE_MODAL); + assert(entry->clientdata!=NULL); + buffer = wstrappend(wapp->app_icon ? wapp->app_icon->wm_class : NULL, + _(" will be forcibly closed.\n" + "Any unsaved changes will be lost.\n" + "Please confirm.")); + wretain(wapp->main_window_desc); if (wPreferences.dont_confirm_kill || wMessageDialog(menu->frame->screen_ptr, _("Kill Application"), - _("This will kill the application.\nAny unsaved changes will be lost.\nPlease confirm."), - _("Yes"), _("No"), NULL)==WAPRDefault) { + buffer, _("Yes"), _("No"), NULL)==WAPRDefault) { if (!wapp->main_window_desc->flags.destroyed) wClientKill(wapp->main_window_desc); } wrelease(wapp->main_window_desc); + + free(buffer); + + WCHANGE_STATE(WSTATE_NORMAL); } @@ -666,7 +681,7 @@ appIconMouseDown(WObjDescriptor *desc, XEvent *event) int clickButton = event->xbutton.button; Pixmap ghost = None; - if (aicon->editing) + if (aicon->editing || WCHECK_STATE(WSTATE_MODAL)) return; if (IsDoubleClick(scr, event)) { diff --git a/src/client.c b/src/client.c index f8f35ee0..2c1045ec 100644 --- a/src/client.c +++ b/src/client.c @@ -288,6 +288,7 @@ void wClientKill(WWindow *wwin) { XKillClient(dpy, wwin->client_win); + XFlush(dpy); } @@ -743,8 +744,8 @@ GetColormapWindows(WWindow *wwin) wwin->cmap_windows = NULL; wwin->cmap_window_no = 0; - if (XGetWMColormapWindows(dpy, wwin->client_win, &(wwin->cmap_windows), - &(wwin->cmap_window_no))==0 + if (!XGetWMColormapWindows(dpy, wwin->client_win, &(wwin->cmap_windows), + &(wwin->cmap_window_no)) || !wwin->cmap_windows) { wwin->cmap_window_no = 0; wwin->cmap_windows = NULL; diff --git a/src/colormap.c b/src/colormap.c index b49b84b1..50b1f459 100644 --- a/src/colormap.c +++ b/src/colormap.c @@ -41,7 +41,7 @@ wColormapInstallForWindow(WScreen *scr, WWindow *wwin) int done = 0; Window xwin = None; - if(wwin) { + if (wwin) { xwin = wwin->client_win; } else { xwin = scr->root_win; @@ -55,7 +55,7 @@ wColormapInstallForWindow(WScreen *scr, WWindow *wwin) } /* install colormap for all windows of the client */ - if (wwin && wwin->cmap_window_no > 0) { + if (wwin && wwin->cmap_window_no > 0 && wwin->cmap_windows) { for (i = wwin->cmap_window_no - 1; i >= 0; i--) { Window w; diff --git a/src/config.h b/src/config.h index 36b1fa1a..6dfca6a7 100644 --- a/src/config.h +++ b/src/config.h @@ -51,7 +51,7 @@ /* #undef X_DISPLAY_MISSING */ /* define to the path to cpp */ -#define CPP_PATH "/lib/cpp" +#define CPP_PATH "/usr/bin/cpp" /* define if you want GNOME stuff support */ /* #undef GNOME_STUFF */ @@ -174,5 +174,5 @@ #define PACKAGE "WindowMaker" /* Version number of package */ -#define VERSION "0.51.1" +#define VERSION "0.51.2" diff --git a/src/dialog.c b/src/dialog.c index a5516af3..33f03c50 100644 --- a/src/dialog.c +++ b/src/dialog.c @@ -70,7 +70,7 @@ wMessageDialog(WScreen *scr, char *title, char *message, parent = XCreateSimpleWindow(dpy, scr->root_win, 0, 0, 400, 180, 0, 0, 0); XReparentWindow(dpy, WMWidgetXID(panel->win), parent, 0, 0); - + wwin = wManageInternalWindow(scr, parent, None, NULL, (scr->scr_width - 400)/2, (scr->scr_height - 180)/2, 400, 180); @@ -452,7 +452,7 @@ wIconChooserDialog(WScreen *scr, char **file, char *instance, char *class) panel->fileField = WMCreateTextField(panel->win); WMResizeWidget(panel->fileField, 345, 20); WMMoveWidget(panel->fileField, 95, 210); - WMSetTextFieldEnabled(panel->fileField, False); + WMSetTextFieldEditable(panel->fileField, False); panel->okButton = WMCreateCommandButton(panel->win); WMResizeWidget(panel->okButton, 80, 26); @@ -614,10 +614,10 @@ destroyInfoPanel(WCoreWindow *foo, void *data, XEvent *event) #endif /* SILLYNESS */ WMUnmapWidget(thePanel); - WMDestroyWidget(thePanel->win); - wUnmanageWindow(thePanel->wwin, False, False); + WMDestroyWidget(thePanel->win); + free(thePanel); thePanel = NULL; diff --git a/src/dock.c b/src/dock.c index 25b6d80c..00fc49ab 100644 --- a/src/dock.c +++ b/src/dock.c @@ -80,7 +80,6 @@ extern void DestroyDockAppSettingsPanel(); extern void ShowDockAppSettingsPanel(WAppIcon *aicon); - extern Cursor wCursor[WCUR_LAST]; extern WPreferences wPreferences; @@ -243,14 +242,21 @@ killCallback(WMenu *menu, WMenuEntry *entry) WAppIconAppList *tapplist; extern Atom _XA_WM_DELETE_WINDOW; +#else + char *buffer; #endif + if (!WCHECK_STATE(WSTATE_NORMAL)) + return; + assert(entry->clientdata!=NULL); icon = (WAppIcon*)entry->clientdata; - + icon->editing = 1; - + + WCHANGE_STATE(WSTATE_MODAL); + #ifdef REDUCE_APPICONS /* Send a delete message to the main window of each application * bound to this docked appicon. - cls @@ -268,10 +274,14 @@ killCallback(WMenu *menu, WMenuEntry *entry) tapplist = tapplist->next; } #else + buffer = wstrappend(icon->wm_class, + _(" will be forcibly closed.\n" + "Any unsaved changes will be lost.\n" + "Please confirm.")); + if (wPreferences.dont_confirm_kill || wMessageDialog(menu->frame->screen_ptr, _("Kill Application"), - _("This will kill the application.\nAny unsaved changes will be lost.\nPlease confirm."), - _("Yes"), _("No"), NULL)==WAPRDefault) { + buffer, _("Yes"), _("No"), NULL)==WAPRDefault) { if (icon->icon && icon->icon->owner) { wClientKill(icon->icon->owner); } @@ -279,7 +289,8 @@ killCallback(WMenu *menu, WMenuEntry *entry) #endif /* !REDUCE_APPICONS */ icon->editing = 0; -} + + WCHANGE_STATE(WSTATE_NORMAL);} static LinkedList* @@ -3766,7 +3777,7 @@ iconMouseDown(WObjDescriptor *desc, XEvent *event) WDock *dock = aicon->dock; WScreen *scr = aicon->icon->core->screen_ptr; - if (aicon->editing) + if (aicon->editing || WCHECK_STATE(WSTATE_MODAL)) return; scr->last_dock = dock; diff --git a/src/event.c b/src/event.c index f8e8fbff..5c9d8402 100644 --- a/src/event.c +++ b/src/event.c @@ -95,7 +95,6 @@ extern int wShapeEventBase; #endif /* special flags */ -extern char WProgramState; extern char WDelayedActionSet; @@ -205,8 +204,8 @@ DispatchEvent(XEvent *event) if (deathHandler) handleDeadProcess(NULL); - if (WProgramState==WSTATE_NEED_EXIT) { - WProgramState = WSTATE_EXITING; + if (WCHECK_STATE(WSTATE_NEED_EXIT)) { + WCHANGE_STATE(WSTATE_EXITING); /* received SIGTERM */ /* * WMHandleEvent() can't be called from anything @@ -215,8 +214,8 @@ DispatchEvent(XEvent *event) */ Shutdown(WSExitMode); - } else if (WProgramState == WSTATE_NEED_RESTART) { - WProgramState = WSTATE_RESTARTING; + } else if (WCHECK_STATE(WSTATE_NEED_RESTART)) { + WCHANGE_STATE(WSTATE_RESTARTING); Shutdown(WSRestartPreparationMode); /* received SIGHUP */ @@ -354,7 +353,7 @@ void NotifyDeadProcess(pid_t pid, unsigned char status) { if (deadProcessPtr>=MAX_DEAD_PROCESSES-1) { - wwarning(_("stack overflow: too many dead processes")); + wwarning("stack overflow: too many dead processes"); return; } /* stack the process to be handled later, @@ -502,45 +501,29 @@ handleMapRequest(XEvent *ev) } if (wwin) { - int state; - - if (wwin->wm_hints && (wwin->wm_hints->flags & StateHint)) - state = wwin->wm_hints->initial_state; - else - state = NormalState; - - if (state == IconicState) - wwin->flags.miniaturized = 1; + wClientSetState(wwin, NormalState, None); + if (wwin->flags.maximized) { + wMaximizeWindow(wwin, wwin->flags.maximized); + } + if (wwin->flags.shaded) { + wwin->flags.shaded = 0; + wwin->flags.skip_next_animation = 1; + wShadeWindow(wwin); + } + if (wwin->flags.miniaturized) { + wwin->flags.miniaturized = 0; + wwin->flags.skip_next_animation = 1; + wIconifyWindow(wwin); + } + if (wwin->flags.hidden) { + WApplication *wapp = wApplicationOf(wwin->main_window); - if (state == WithdrawnState) { - wwin->flags.mapped = 0; - wClientSetState(wwin, WithdrawnState, None); - wUnmanageWindow(wwin, True, False); - } else { - wClientSetState(wwin, NormalState, None); - if (wwin->flags.maximized) { - wMaximizeWindow(wwin, wwin->flags.maximized); + wwin->flags.hidden = 0; + wwin->flags.skip_next_animation = 1; + if (wapp) { + wHideApplication(wapp); } - if (wwin->flags.shaded) { - wwin->flags.shaded = 0; - wwin->flags.skip_next_animation = 1; - wShadeWindow(wwin); - } - if (wwin->flags.miniaturized) { - wwin->flags.miniaturized = 0; - wwin->flags.skip_next_animation = 1; - wIconifyWindow(wwin); - } - if (wwin->flags.hidden) { - WApplication *wapp = wApplicationOf(wwin->main_window); - - wwin->flags.hidden = 0; - wwin->flags.skip_next_animation = 1; - if (wapp) { - wHideApplication(wapp); - } - } - } + } } } @@ -1701,6 +1684,7 @@ handleMotionNotify(XEvent *event) { WMenu *menu; WScreen *scr = wScreenForRootWindow(event->xmotion.root); + WWindow *wwin; if (wPreferences.scrollable_menus) { if (event->xmotion.x_root <= 1 || @@ -1717,6 +1701,53 @@ handleMotionNotify(XEvent *event) wMenuScroll(menu, event); } } +#if 0 + if (event->xmotion.subwindow == None) + return; + + if (scr->scrolledFMaximize != None) { + WWindow *twin; + + twin = wWindowFor(scr->scrolledFMaximize); + if (twin && twin->frame_y ==) { + + + } + scr->scrolledFMaximize = NULL; + + } else { + + /* scroll full maximized window */ + if (event->xmotion.y_root < 1 + || event->xmotion.y_root > scr->scr_height - 1) { + + wwin = wWindowFor(event->xmotion.subwindow); + + if (wwin && (wwin->flags.maximized & MAX_VERTICAL) + && WFLAGP(wwin, full_maximize) + && event->xmotion.x_root >= wwin->frame_x + && event->xmotion.x_root <= wwin->frame_x + wwin->frame->core->width) { + + if (!WFLAGP(wwin, no_titlebar) + && wwin->frame_y <= - wwin->frame->top_width) { + + wWindowMove(wwin, wwin->frame_x, 0); + wwin->flags.dragged_while_fmaximized = 0; + + } else if (!WFLAGP(wwin, no_resizebar) + && wwin->frame_y + wwin->frame->core->height >= + scr->scr_height + wwin->frame->bottom_width) { + + int y = scr->scr_height + wwin->frame->bottom_width; + + y = scr->scr_height - wwin->frame_y - wwin->frame->core->height; + + wWindowMove(wwin, wwin->frame_x, y); + wwin->flags.dragged_while_fmaximized = 0; + } + } + } +#endif } diff --git a/src/icon.c b/src/icon.c index 14c6a764..5b27a21b 100644 --- a/src/icon.c +++ b/src/icon.c @@ -417,7 +417,6 @@ getnameforicon(WWindow *wwin) len = strlen(prefix)+64+strlen(suffix); path = wmalloc(len+1); sprintf(path, "%s/.AppInfo", prefix); - free(prefix); if (access(path, F_OK)!=0) { if (mkdir(path, S_IRUSR|S_IWUSR|S_IXUSR)) { @@ -811,7 +810,9 @@ miniwindowMouseDown(WObjDescriptor *desc, XEvent *event) int grabbed=0; int clickButton=event->xbutton.button; - + if (WCHECK_STATE(WSTATE_MODAL)) + return; + if (IsDoubleClick(icon->core->screen_ptr, event)) { miniwindowDblClick(desc, event); return; diff --git a/src/kwm.c b/src/kwm.c index 7fa085a8..cb0a52bd 100644 --- a/src/kwm.c +++ b/src/kwm.c @@ -1559,6 +1559,7 @@ wKWMSendEventMessage(WWindow *wwin, WKWMEventMessage message) if (wwin && (wwin->flags.internal_window || wwin->flags.kwm_hidden_for_modules + || !wwin->flags.kwm_managed || WFLAGP(wwin, skip_window_list))) return; diff --git a/src/moveres.c b/src/moveres.c index 9b0892b6..7c73299e 100644 --- a/src/moveres.c +++ b/src/moveres.c @@ -581,8 +581,8 @@ typedef struct { #define WTOP(w) (w)->frame_y #define WLEFT(w) (w)->frame_x -#define WRIGHT(w) ((w)->frame_x + (int)(w)->frame->core->width) -#define WBOTTOM(w) ((w)->frame_y + (int)(w)->frame->core->height) +#define WRIGHT(w) ((w)->frame_x + (int)(w)->frame->core->width + FRAME_BORDER_WIDTH) +#define WBOTTOM(w) ((w)->frame_y + (int)(w)->frame->core->height + FRAME_BORDER_WIDTH) static int compareWTop(const void *a, const void *b) @@ -749,6 +749,8 @@ updateMoveData(WWindow *wwin, MoveData *data) tmp = scr->focused_window; while (tmp) { if (tmp != wwin && scr->current_workspace == tmp->frame->workspace + && !tmp->flags.miniaturized + && !tmp->flags.hidden && !tmp->flags.obscured) { data->topList[data->count] = tmp; data->leftList[data->count] = tmp; @@ -823,15 +825,14 @@ initMoveData(WWindow *wwin, MoveData *data) tmp != NULL; tmp = tmp->prev, i++); - if (i <= 1) - return; - - data->topList = wmalloc(sizeof(WWindow*) * i); - data->leftList = wmalloc(sizeof(WWindow*) * i); - data->rightList = wmalloc(sizeof(WWindow*) * i); - data->bottomList = wmalloc(sizeof(WWindow*) * i); + if (i > 1) { + data->topList = wmalloc(sizeof(WWindow*) * i); + data->leftList = wmalloc(sizeof(WWindow*) * i); + data->rightList = wmalloc(sizeof(WWindow*) * i); + data->bottomList = wmalloc(sizeof(WWindow*) * i); - updateMoveData(wwin, data); + updateMoveData(wwin, data); + } data->realX = wwin->frame_x; data->realY = wwin->frame_y; @@ -1075,28 +1076,34 @@ updateWindowPosition(WWindow *wwin, MoveData *data, Bool doResistance, drawFrames(wwin, scr->selected_windows, data->realX - wwin->frame_x, data->realY - wwin->frame_y); + } + + if (!scr->selected_windows + && wPreferences.move_display == WDIS_FRAME_CENTER) { + + moveGeometryDisplayCentered(scr, newX + data->winWidth/2, + newY + data->winHeight/2); + } + if (!opaqueMove) { /* draw frames */ drawFrames(wwin, scr->selected_windows, newX - wwin->frame_x, newY - wwin->frame_y); } - } - if (!scr->selected_windows) { + if (!scr->selected_windows) { - if (wPreferences.move_display == WDIS_NEW) { + if (wPreferences.move_display == WDIS_NEW) { - showPosition(wwin, data->realX, data->realY); - - } else if (wPreferences.move_display == WDIS_FRAME_CENTER) { - - moveGeometryDisplayCentered(scr, newX + data->winWidth/2, - newY + data->winHeight/2); + showPosition(wwin, data->realX, data->realY); + + } + showPosition(wwin, newX, newY); } - showPosition(wwin, newX, newY); } + /* recalc relative window position */ if (doResistance && (data->realX != newX || data->realY != newY)) { updateResistance(wwin, data, newX, newY); @@ -1591,7 +1598,7 @@ wMouseMoveWindow(WWindow *wwin, XEvent *ev) freeMoveData(&moveData); return started; - + default: if (started && !opaqueMove) { drawFrames(wwin, scr->selected_windows, diff --git a/src/properties.c b/src/properties.c index 383d1f15..1f56f8af 100644 --- a/src/properties.c +++ b/src/properties.c @@ -291,6 +291,25 @@ PropWriteGNUstepWMAttr(Window window, GNUstepWMAttributes *attr) } +int +PropGetWindowState(Window window) +{ + long *data; + long state; + + data = (long*)PropGetCheckProperty(window, _XA_WM_STATE, _XA_WM_STATE, + 32, 1, NULL); + + if (!data) + return -1; + + state = *data; + XFree(data); + + return state; +} + + void PropCleanUp(Window root) { diff --git a/src/properties.h b/src/properties.h index 91826f28..2543f831 100644 --- a/src/properties.h +++ b/src/properties.h @@ -28,6 +28,7 @@ unsigned char* PropGetCheckProperty(Window window, Atom hint, Atom type, int format, int count, int *retCount); +int PropGetWindowState(Window window); int PropGetNormalHints(Window window, XSizeHints *size_hints, int *pre_iccm); void PropGetProtocols(Window window, WProtocols *prots); diff --git a/src/screen.c b/src/screen.c index 75725e9f..f8a774fc 100644 --- a/src/screen.c +++ b/src/screen.c @@ -501,7 +501,7 @@ createInternalWindows(WScreen *scr) XSelectInput(dpy, scr->no_focus_win, KeyPressMask|KeyReleaseMask); XMapWindow(dpy, scr->no_focus_win); - XSetInputFocus (dpy, scr->no_focus_win, RevertToParent, CurrentTime); + XSetInputFocus(dpy, scr->no_focus_win, RevertToParent, CurrentTime); /* shadow window for dock buttons */ vmask = CWBorderPixel|CWBackPixmap|CWBackPixel|CWCursor|CWSaveUnder|CWOverrideRedirect; diff --git a/src/screen.h b/src/screen.h index bd996864..7a227f40 100644 --- a/src/screen.h +++ b/src/screen.h @@ -265,7 +265,11 @@ typedef struct _WScreen { WMHandlerID *autoRaiseTimer; Window autoRaiseWindow; /* window that is scheduled to be * raised */ - + + + Window scrolledFMaximize; /* full maximized window which was + scrolled down for titlebar access */ + /* for window shortcuts */ struct WWindow *shortcutWindow[MAX_WINDOW_SHORTCUTS]; diff --git a/src/session.c b/src/session.c index ca6021f5..f95c929c 100644 --- a/src/session.c +++ b/src/session.c @@ -870,8 +870,6 @@ smSaveYourselfPhase2Proc(SmcConn smc_conn, SmPointer client_data) statefile = malloc(strlen(prefix)+64); if (!statefile) { - if (gsPrefix) - free(prefix); wwarning(_("out of memory while saving session state")); goto fail; } @@ -887,9 +885,6 @@ smSaveYourselfPhase2Proc(SmcConn smc_conn, SmPointer client_data) i++; } while (access(F_OK, statefile)!=-1); - if (gsPrefix) - free(prefix); - /* save the states of all windows we're managing */ state = PLMakeArrayFromElements(NULL, NULL); diff --git a/src/shutdown.c b/src/shutdown.c index 215d6ead..c8e2b84a 100644 --- a/src/shutdown.c +++ b/src/shutdown.c @@ -187,9 +187,12 @@ RestoreDesktop(WScreen *scr) next = core->stacking->above; if (core->descriptor.parent_type==WCLASS_WINDOW) { + Window window; + wwin = core->descriptor.parent; - wwin->flags.mapped=1; + window = wwin->client_win; wUnmanageWindow(wwin, !wwin->flags.internal_window, False); + XMapWindow(dpy, window); } core = next; } diff --git a/src/startup.c b/src/startup.c index 2702831c..80ef931e 100644 --- a/src/startup.c +++ b/src/startup.c @@ -54,6 +54,7 @@ #include "framewin.h" #include "session.h" #include "defaults.h" +#include "properties.h" #include "xutil.h" @@ -139,7 +140,6 @@ extern Atom _XDE_URLTYPE; extern Cursor wCursor[WCUR_LAST]; /* special flags */ -extern char WProgramState; extern char WDelayedActionSet; /***** Local *****/ @@ -261,7 +261,7 @@ handleSig(int sig) wwarning(_("got signal %i - restarting\n"), sig); #endif - WProgramState = WSTATE_NEED_RESTART; + WCHANGE_STATE(WSTATE_NEED_RESTART); /* setup idle handler, so that this will be handled when * the select() is returned becaused of the signal, even if @@ -278,7 +278,7 @@ handleSig(int sig) wwarning(_("got signal %i - exiting...\n"), sig); #endif - WProgramState = WSTATE_NEED_EXIT; + WCHANGE_STATE(WSTATE_NEED_EXIT); if (!WDelayedActionSet) { WDelayedActionSet = 1; @@ -864,27 +864,6 @@ StartUp(Bool defaultScreenOnly) -static int -getState(Window window) -{ - Atom type; - int form; - unsigned long nitems, bytes_rem; - unsigned char *data; - long ret; - - if (XGetWindowProperty(dpy, window, _XA_WM_STATE, 0, 3, False, - _XA_WM_STATE, &type,&form,&nitems,&bytes_rem, - &data)==Success) { - if (data != NULL) { - ret = *(long*)data; - free(data); - return ret; - } - } - return -1; -} - static Bool windowInList(Window window, Window *list, int count) @@ -913,12 +892,9 @@ manageAllWindows(WScreen *scr) Window root, parent; Window *children; unsigned int nchildren; - XWindowAttributes wattribs; unsigned int i, j; - int state; WWindow *wwin; - XWMHints *wmhints; - + XGrabServer(dpy); XQueryTree(dpy, scr->root_win, &root, &parent, &children, &nchildren); @@ -926,8 +902,10 @@ manageAllWindows(WScreen *scr) /* first remove all icon windows */ for (i = 0; i < nchildren; i++) { + XWMHints *wmhints; + if (children[i]==None) - continue; + continue; wmhints = XGetWMHints(dpy, children[i]); if (wmhints && (wmhints->flags & IconWindowHint)) { @@ -944,61 +922,34 @@ manageAllWindows(WScreen *scr) XFree(wmhints); } } - /* map all windows without OverrideRedirect */ + + for (i = 0; i < nchildren; i++) { if (children[i] == None) continue; - #ifdef KWM_HINTS wKWMCheckModule(scr, children[i]); #endif - - XGetWindowAttributes(dpy, children[i], &wattribs); - - state = getState(children[i]); - if (!wattribs.override_redirect - && (state>=0 || wattribs.map_state!=IsUnmapped)) { - - if (state==WithdrawnState) { - /* move the window far away so that it doesn't flash */ - XMoveWindow(dpy, children[i], scr->scr_width+10, - scr->scr_height+10); + wwin = wManageWindow(scr, children[i]); + if (wwin) { + /* apply states got from WSavedState */ + /* shaded + minimized is not restored correctly */ + if (wwin->flags.shaded) { + wwin->flags.shaded = 0; + wShadeWindow(wwin); } - wwin = wManageWindow(scr, children[i]); - if (wwin) { - if (state == WithdrawnState) { - wwin->flags.mapped = 0; - wClientSetState(wwin, WithdrawnState, None); - XSelectInput(dpy, wwin->client_win, NoEventMask); - XRemoveFromSaveSet(dpy, wwin->client_win); - wUnmanageWindow(wwin, True, False); - } else { - /* apply states got from WSavedState */ - /* shaded + minimized is not restored correctly */ - if (wwin->flags.shaded) { - wwin->flags.shaded = 0; - wShadeWindow(wwin); - } - if (wwin->wm_hints && - (wwin->wm_hints->flags & StateHint) && state < 0) - state = wwin->wm_hints->initial_state; - - if ((state == IconicState || wwin->flags.miniaturized) - && (wwin->transient_for == None - || wwin->transient_for == wwin->client_win - || !windowInList(wwin->transient_for, - children, nchildren))) { - wwin->flags.miniaturized = 0; - wIconifyWindow(wwin); - } else { - wClientSetState(wwin, NormalState, None); - } - } - } - if (state == WithdrawnState) { - /* move the window back to it's old position */ - XMoveWindow(dpy, children[i], wattribs.x, wattribs.y); + if (wwin->flags.miniaturized + && (wwin->transient_for == None + || wwin->transient_for == scr->root_win + || !windowInList(wwin->transient_for, children, + nchildren))) { + + wwin->flags.skip_next_animation = 1; + wwin->flags.miniaturized = 0; + wIconifyWindow(wwin); + } else { + wClientSetState(wwin, NormalState, None); } } } diff --git a/src/wconfig.h b/src/wconfig.h index 23a371c0..19a4c5a7 100644 --- a/src/wconfig.h +++ b/src/wconfig.h @@ -57,7 +57,7 @@ */ #define USECPP -/* #define CPP_PATH /lib/cpp */ +/* #define CPP_PATH /usr/bin/cpp */ /* * support for OffiX DND drag and drop in the Dock diff --git a/src/wdefaults.c b/src/wdefaults.c index 389729b6..80f5a490 100644 --- a/src/wdefaults.c +++ b/src/wdefaults.c @@ -82,6 +82,7 @@ static proplist_t AStartMaximized; static proplist_t AStartHidden; /* app */ static proplist_t ADontSaveSession; /* app */ static proplist_t AEmulateAppIcon; +static proplist_t AFullMaximize; static proplist_t AStartWorkspace; @@ -117,6 +118,7 @@ init_wdefaults(WScreen *scr) AStartMaximized = PLMakeString("StartMaximized"); ADontSaveSession = PLMakeString("DontSaveSession"); AEmulateAppIcon = PLMakeString("EmulateAppIcon"); + AFullMaximize = PLMakeString("FullMaximize"); AStartWorkspace = PLMakeString("StartWorkspace"); @@ -299,6 +301,9 @@ wDefaultFillAttributes(WScreen *scr, char *instance, char *class, value = get_value(dw, dc, dn, da, AEmulateAppIcon, No, useGlobalDefault); APPLY_VAL(value, emulate_appicon, AEmulateAppIcon); + value = get_value(dw, dc, dn, da, AFullMaximize, No, useGlobalDefault); + APPLY_VAL(value, emulate_appicon, AFullMaximize); + /* clean up */ PLSetStringCmpHook(StringCompareHook); } diff --git a/src/window.c b/src/window.c index bea3ef03..10830cfd 100644 --- a/src/window.c +++ b/src/window.c @@ -107,8 +107,7 @@ static FocusMode getFocusMode(WWindow *wwin); static int getSavedState(Window window, WSavedState **state); -static void setupGNUstepHints(WWindow *wwin, - GNUstepWMAttributes *gs_hints); +static void setupGNUstepHints(WWindow *wwin, GNUstepWMAttributes *gs_hints); /* event handlers */ @@ -226,39 +225,38 @@ static void setupGNUstepHints(WWindow *wwin, GNUstepWMAttributes *gs_hints) { if (gs_hints->flags & GSWindowStyleAttr) { - WSETUFLAG(wwin, no_titlebar, - ((gs_hints->window_style & WMTitledWindowMask)?0:1)); - - WSETUFLAG(wwin, no_close_button, - ((gs_hints->window_style & WMClosableWindowMask)?0:1)); + wwin->client_flags.no_titlebar = + ((gs_hints->window_style & WMTitledWindowMask)?0:1); + + wwin->client_flags.no_close_button = + ((gs_hints->window_style & WMClosableWindowMask)?0:1); - WSETUFLAG(wwin, no_closable, - ((gs_hints->window_style & WMClosableWindowMask)?0:1)); + wwin->client_flags.no_closable = + ((gs_hints->window_style & WMClosableWindowMask)?0:1); - WSETUFLAG(wwin, no_miniaturize_button, - ((gs_hints->window_style & WMMiniaturizableWindowMask)?0:1)); + wwin->client_flags.no_miniaturize_button = + ((gs_hints->window_style & WMMiniaturizableWindowMask)?0:1); - WSETUFLAG(wwin, no_miniaturizable, - ((gs_hints->window_style & WMMiniaturizableWindowMask)?0:1)); + wwin->client_flags.no_miniaturizable = + ((gs_hints->window_style & WMMiniaturizableWindowMask)?0:1); - WSETUFLAG(wwin, no_resizebar, - ((gs_hints->window_style & WMResizableWindowMask)?0:1)); + wwin->client_flags.no_resizebar = + ((gs_hints->window_style & WMResizableWindowMask)?0:1); - WSETUFLAG(wwin, no_resizable, - ((gs_hints->window_style & WMResizableWindowMask)?0:1)); + wwin->client_flags.no_resizable = + ((gs_hints->window_style & WMResizableWindowMask)?0:1); } else { /* setup the defaults */ - WSETUFLAG(wwin, no_titlebar, 0); - WSETUFLAG(wwin, no_closable, 0); - WSETUFLAG(wwin, no_miniaturizable, 0); - WSETUFLAG(wwin, no_resizable, 0); - WSETUFLAG(wwin, no_close_button, 0); - WSETUFLAG(wwin, no_miniaturize_button, 0); - WSETUFLAG(wwin, no_resizebar, 0); + wwin->client_flags.no_titlebar = 0; + wwin->client_flags.no_closable = 0; + wwin->client_flags.no_miniaturizable = 0; + wwin->client_flags.no_resizable = 0; + wwin->client_flags.no_close_button = 0; + wwin->client_flags.no_miniaturize_button = 0; + wwin->client_flags.no_resizebar = 0; } - if (gs_hints->extra_flags & GSNoApplicationIconFlag) { - WSETUFLAG(wwin, no_appicon, 1); + wwin->client_flags.no_appicon = 1; } } @@ -425,7 +423,7 @@ wWindowSetupInitialAttributes(WWindow *wwin, int *level, int *workspace) Bool wWindowCanReceiveFocus(WWindow *wwin) { - if (!wwin->flags.mapped && (!wwin->flags.shaded || wwin->flags.hidden)) + if (!wwin->flags.mapped && !wwin->flags.shaded) return False; if (WFLAGP(wwin, no_focusable) || wwin->flags.miniaturized) return False; @@ -469,6 +467,9 @@ wWindowObscuresWindow(WWindow *wwin, WWindow *obscured) * the window decoration attributes and others. User preferences * for the window are used if available, to configure window * decorations and some behaviour. + * If in startup, windows that are override redirect, + * unmapped and never were managed and are Withdrawn are not + * managed. * * Returns: * the new window descriptor @@ -494,12 +495,14 @@ wManageWindow(WScreen *scr, Window window) WWindowState *win_state; WWindow *transientOwner = NULL; int window_level; + int wm_state; int foo; int workspace = -1; char *title; + Bool withdraw = False; /* mutex. */ - XGrabServer(dpy); +// XGrabServer(dpy); XSync(dpy, False); /* make sure the window is still there */ if (!XGetWindowAttributes(dpy, window, &wattribs)) { @@ -507,6 +510,20 @@ wManageWindow(WScreen *scr, Window window) return NULL; } + /* if it's an override-redirect, ignore it */ + if (wattribs.override_redirect) { + XUngrabServer(dpy); + return NULL; + } + + wm_state = PropGetWindowState(window); + + /* if it's startup and the window is unmapped, don't manage it */ + if (scr->flags.startup && wm_state < 0 && wattribs.map_state==IsUnmapped) { + XUngrabServer(dpy); + return NULL; + } + if (!wFetchName(dpy, window, &title)) { title = NULL; } @@ -548,7 +565,6 @@ wManageWindow(WScreen *scr, Window window) * *-------------------------------------------------- */ - wwin->wm_hints = XGetWMHints(dpy, window); PropGetWMClass(window, &wwin->wm_class, &wwin->wm_instance); /* setup descriptor */ @@ -569,24 +585,26 @@ wManageWindow(WScreen *scr, Window window) if (!PropGetGNUstepWMAttr(window, &wwin->wm_gnustep_attr)) { wwin->wm_gnustep_attr = NULL; } - + wwin->client_leader = PropGetClientLeader(window); if (wwin->client_leader!=None) wwin->main_window = wwin->client_leader; - if (wwin->wm_hints) - XFree(wwin->wm_hints); - wwin->wm_hints = XGetWMHints(dpy, window); if (wwin->wm_hints) { - if ((wwin->wm_hints->flags&StateHint) - && (wwin->wm_hints->initial_state == IconicState)) { - wwin->flags.miniaturized = 1; - /* don't do iconify animation */ - wwin->flags.skip_next_animation = 1; + if (wwin->wm_hints->flags & StateHint) { + + if (wwin->wm_hints->initial_state == IconicState) { + + wwin->flags.miniaturized = 1; + + } else if (wwin->wm_hints->initial_state == WithdrawnState) { + + withdraw = True; + } } - + if (wwin->wm_hints->flags & WindowGroupHint) { wwin->group_id = wwin->wm_hints->window_group; /* window_group has priority over CLIENT_LEADER */ @@ -686,19 +704,34 @@ wManageWindow(WScreen *scr, Window window) wKWMCheckClientInitialState(wwin); #endif - /* if there is a saved state, restore it */ + /* apply previous state if it exists and we're in startup */ + if (scr->flags.startup && wm_state >= 0) { + + if (wm_state == IconicState) { + + wwin->flags.miniaturized = 1; + + } else if (wm_state == WithdrawnState) { + + withdraw = True; + } + } + + /* if there is a saved state (from file), restore it */ win_state = NULL; if (wwin->main_window!=None/* && wwin->main_window!=window*/) { win_state = (WWindowState*)wWindowGetSavedState(wwin->main_window); } else { win_state = (WWindowState*)wWindowGetSavedState(window); } - if (win_state && !(wwin->wm_hints && wwin->wm_hints->flags&StateHint && - wwin->wm_hints->initial_state==WithdrawnState)) { + if (win_state && !withdraw) { + if (win_state->state->hidden>0) wwin->flags.hidden = win_state->state->hidden; + if (win_state->state->shaded>0 && !WFLAGP(wwin, no_shadeable)) wwin->flags.shaded = win_state->state->shaded; + if (win_state->state->miniaturized>0 && !WFLAGP(wwin, no_miniaturizable)) { wwin->flags.miniaturized = win_state->state->miniaturized; @@ -718,22 +751,23 @@ wManageWindow(WScreen *scr, Window window) } } - /* if we're restarting, restore saved state. This will overwrite previous */ + /* if we're restarting, restore saved state (from hints). + * This will overwrite previous */ { WSavedState *wstate; if (getSavedState(window, &wstate)) { wwin->flags.shaded = wstate->shaded; wwin->flags.hidden = wstate->hidden; - wwin->flags.miniaturized = 0; + wwin->flags.miniaturized = wstate->miniaturized; workspace = wstate->workspace; free(wstate); } } /* don't let transients start miniaturized if their owners are not */ - if (transientOwner && !transientOwner->flags.miniaturized - && wwin->flags.miniaturized) { + if (transientOwner && !transientOwner->flags.miniaturized + && wwin->flags.miniaturized && !withdraw) { wwin->flags.miniaturized = 0; if (wwin->wm_hints) wwin->wm_hints->initial_state = NormalState; @@ -774,8 +808,7 @@ wManageWindow(WScreen *scr, Window window) /* do not ask for window placement if the window is * transient, during startup, if the initial workspace is another one - * or if the window wants to - * start iconic. + * or if the window wants to start iconic. * If geometry was saved, restore it. */ { Bool dontBring = False; @@ -783,9 +816,9 @@ wManageWindow(WScreen *scr, Window window) if (win_state && win_state->state->use_geometry) { x = win_state->state->x; y = win_state->state->y; - } else if (wwin->transient_for==None && !scr->flags.startup && - workspace==scr->current_workspace - && !wwin->flags.miniaturized + } else if (wwin->transient_for==None && !scr->flags.startup + && workspace == scr->current_workspace + && !wwin->flags.miniaturized && !wwin->flags.maximized && !(wwin->normal_hints->flags & (USPosition|PPosition))) { PlaceWindow(wwin, &x, &y, width, height); @@ -796,14 +829,19 @@ wManageWindow(WScreen *scr, Window window) if (WFLAGP(wwin, dont_move_off) && dontBring) wScreenBringInside(scr, &x, &y, width, height); } - /* + + if (wwin->flags.urgent) { + if (!IS_OMNIPRESENT(wwin)) + wwin->flags.omnipresent ^= 1; + } + + /* *-------------------------------------------------- * * Create frame, borders and do reparenting * *-------------------------------------------------- */ - foo = WFF_LEFT_BUTTON | WFF_RIGHT_BUTTON; if (!WFLAGP(wwin, no_titlebar)) foo |= WFF_TITLEBAR; @@ -941,11 +979,9 @@ wManageWindow(WScreen *scr, Window window) XLowerWindow(dpy, window); /* if window is in this workspace and should be mapped, then map it */ - if (!wwin->flags.miniaturized + if (!wwin->flags.miniaturized && (workspace == scr->current_workspace || IS_OMNIPRESENT(wwin)) - && !wwin->flags.hidden - && !(wwin->wm_hints && (wwin->wm_hints->flags & StateHint) - && wwin->wm_hints->initial_state == WithdrawnState)) { + && !wwin->flags.hidden && !withdraw) { /* The following "if" is to avoid crashing of clients that expect * WM_STATE set before they get mapped. Else WM_STATE is set later, @@ -962,7 +998,7 @@ wManageWindow(WScreen *scr, Window window) #define _WIDTH(w) (w)->frame->core->width #define _HEIGHT(w) (w)->frame->core->height if (!wPreferences.auto_focus && scr->focused_window - && !scr->flags.startup && !transientOwner + && !scr->flags.startup && !transientOwner && ((wWindowObscuresWindow(wwin, scr->focused_window) && (_WIDTH(wwin) > (_WIDTH(scr->focused_window)*5)/3 || _HEIGHT(wwin) > (_HEIGHT(scr->focused_window)*5)/3) @@ -1029,7 +1065,6 @@ wManageWindow(WScreen *scr, Window window) wwin->prev = NULL; } - #ifdef GNOME_STUFF wGNOMEUpdateClientStateHint(wwin, True); #endif @@ -1039,7 +1074,7 @@ wManageWindow(WScreen *scr, Window window) #endif XUngrabServer(dpy); - + /* *-------------------------------------------------- * @@ -1066,18 +1101,20 @@ wManageWindow(WScreen *scr, Window window) wGNOMEUpdateClientListHint(scr); #endif #ifdef KWM_HINTS + wwin->flags.kwm_managed = 1; + wKWMSendEventMessage(wwin, WKWMAddWindow); #endif - wColormapInstallForWindow(wwin->screen_ptr, scr->cmap_window); + wColormapInstallForWindow(scr, scr->cmap_window); - UpdateSwitchMenu(wwin->screen_ptr, wwin, ACTION_ADD); + UpdateSwitchMenu(scr, wwin, ACTION_ADD); #ifdef OLWM_HINTS if (wwin->client_flags.olwm_warp_to_pin && wwin->frame->titlebar != NULL - && !WFLAGP(wwin, no_close_button)) { + && !WFLAGP(wwin, no_close_button) && !withdraw) { - XWarpPointer(dpy, None, None, 0, 0, 0, 0, + XWarpPointer(dpy, None, None, 0, 0, 0, 0, wwin->frame_x + width - wwin->frame->titlebar->height * 2, wwin->frame_y); } @@ -1085,13 +1122,24 @@ wManageWindow(WScreen *scr, Window window) /* *-------------------------------------------------- + * * Cleanup temporary stuff + * *-------------------------------------------------- */ if (win_state) wWindowDeleteSavedState(win_state); + /* If the window must be withdrawed, then do it now. + * Must do some optimization, 'though */ + if (withdraw) { + wwin->flags.mapped = 0; + wClientSetState(wwin, WithdrawnState, None); + wUnmanageWindow(wwin, True, False); + wwin = NULL; + } + return wwin; } @@ -1265,7 +1313,7 @@ wUnmanageWindow(WWindow *wwin, Bool restore, Bool destroyed) WWindow *pwin = wwin->inspector->frame; /* the inspector window */ (*pwin->frame->on_click_right)(NULL, pwin, NULL); } - + /* Close window menu if it's open for this window */ if (wwin->flags.menu_open_for_me) { CloseWindowMenu(scr); @@ -1276,6 +1324,9 @@ wUnmanageWindow(WWindow *wwin, Bool restore, Bool destroyed) XRemoveFromSaveSet(dpy, wwin->client_win); XSelectInput(dpy, wwin->client_win, NoEventMask); + + XUngrabButton(dpy, AnyButton, AnyModifier, wwin->client_win); + XUngrabKey(dpy, AnyKey, AnyModifier, wwin->client_win); } XUnmapWindow(dpy, frame->window); @@ -2010,6 +2061,7 @@ wWindowSaveState(WWindow *wwin) memset(data, 0, sizeof(CARD32)*9); data[0] = wwin->frame->workspace; + data[1] = wwin->flags.miniaturized; data[2] = wwin->flags.shaded; data[3] = wwin->flags.hidden; @@ -2608,7 +2660,8 @@ titlebarMouseDown(WCoreWindow *sender, void *data, XEvent *event) XUngrabPointer(dpy, CurrentTime); } else if (event->xbutton.button == Button3 && event->xbutton.state==0 - && !wwin->flags.internal_window) { + && !wwin->flags.internal_window + && !WCHECK_STATE(WSTATE_MODAL)) { WObjDescriptor *desc; if (event->xbutton.window != wwin->frame->titlebar->window diff --git a/src/window.h b/src/window.h index 817a5134..ad042395 100644 --- a/src/window.h +++ b/src/window.h @@ -127,6 +127,8 @@ typedef struct { unsigned int start_maximized:1; unsigned int dont_save_session:1; /* do not save app's state in session */ + unsigned int full_maximize:1; + /* * emulate_app_icon must be automatically disabled for apps that can * generate their own appicons and for apps that have no_appicon=1 @@ -268,8 +270,11 @@ typedef struct WWindow { unsigned int waiting_save_ack:1; /* waiting for SAVE_YOURSELF ack */ unsigned int obscured:1; /* window is obscured */ + + unsigned int dragged_while_fmaximized; #ifdef KWM_HINTS unsigned int kwm_hidden_for_modules:1; + unsigned int kwm_managed:1; #endif #ifdef OLWM_HINTS unsigned int olwm_push_pin_out:1;/* emulate pushpin behaviour */ diff --git a/src/winspector.c b/src/winspector.c index 41b47a25..42392608 100644 --- a/src/winspector.c +++ b/src/winspector.c @@ -72,6 +72,7 @@ static proplist_t AStartMiniaturized; static proplist_t AStartMaximized; static proplist_t ADontSaveSession; static proplist_t AEmulateAppIcon; +static proplist_t AFullMaximize; static proplist_t AStartWorkspace; @@ -119,6 +120,7 @@ make_keys() AStartHidden = PLMakeString("StartHidden"); ADontSaveSession = PLMakeString("DontSaveSession"); AEmulateAppIcon = PLMakeString("EmulateAppIcon"); + AFullMaximize = PLMakeString("FullMaximize"); AStartWorkspace = PLMakeString("StartWorkspace"); @@ -532,6 +534,9 @@ saveSettings(WMButton *button, InspectorPanel *panel) value = (WMGetButtonSelected(panel->moreChk[6])!=0) ? Yes : No; insertAttribute(dict, winDic, AEmulateAppIcon, value, &different, flags); + value = (WMGetButtonSelected(panel->moreChk[7])!=0) ? Yes : No; + insertAttribute(dict, winDic, AFullMaximize, value, &different, flags); + /* application wide settings for when */ /* the window is the leader, save the attribute with the others */ if (panel->inspected->main_window == panel->inspected->client_win) { @@ -547,8 +552,9 @@ saveSettings(WMButton *button, InspectorPanel *panel) if (different) { PLInsertDictionaryEntry(dict, key, winDic); } + PLRelease(key); - PLRelease(winDic); + PLRelease(winDic); different = 0; @@ -561,16 +567,16 @@ saveSettings(WMButton *button, InspectorPanel *panel) wapp = wApplicationOf(panel->inspected->main_window); if (wapp) { char *iconFile; - + appDic = PLMakeDictionaryFromEntries(NULL, NULL, NULL); assert(wapp->main_window_desc->wm_instance!=NULL); assert(wapp->main_window_desc->wm_class!=NULL); - + strcat(strcpy(buffer, wapp->main_window_desc->wm_instance), "."); strcat(buffer, wwin->wm_class); key = PLMakeString(buffer); - + iconFile = wDefaultGetIconFile(wwin->screen_ptr, wapp->main_window_desc->wm_instance, wapp->main_window_desc->wm_class, @@ -709,6 +715,7 @@ applySettings(WMButton *button, InspectorPanel *panel) WSETUFLAG(wwin, no_focusable, WMGetButtonSelected(panel->moreChk[4])); WSETUFLAG(wwin, dont_save_session, WMGetButtonSelected(panel->moreChk[5])); WSETUFLAG(wwin, emulate_appicon, WMGetButtonSelected(panel->moreChk[6])); + WSETUFLAG(wwin, full_maximize, WMGetButtonSelected(panel->moreChk[7])); WSETUFLAG(wwin, always_user_icon, WMGetButtonSelected(panel->alwChk)); if (WFLAGP(wwin, no_titlebar) && wwin->flags.shaded) @@ -851,7 +858,7 @@ revertSettings(WMButton *button, InspectorPanel *panel) } WMSetButtonSelected(panel->attrChk[i], flag); } - for (i=0; i < 7; i++) { + for (i=0; i < 8; i++) { int flag = 0; switch (i) { @@ -876,6 +883,9 @@ revertSettings(WMButton *button, InspectorPanel *panel) case 6: flag = WFLAGP(wwin, emulate_appicon); break; + case 7: + flag = WFLAGP(wwin, full_maximize); + break; } WMSetButtonSelected(panel->moreChk[i], flag); } @@ -949,7 +959,7 @@ textEditedObserver(void *observerData, WMNotification *notification) if ((long)WMGetNotificationClientData(notification) != WMReturnTextMovement) return; - if (observerData == panel->fileText) { + if (WMGetNotificationObject(notification) == panel->fileText) { showIconFor(WMWidgetScreen(panel->win), panel, NULL, NULL, USE_TEXT_FIELD); /* @@ -1106,8 +1116,8 @@ createInspectorForWindow(WWindow *wwin) /**** attributes ****/ panel->attrFrm = WMCreateFrame(panel->win); WMSetFrameTitle(panel->attrFrm, _("Attributes")); - WMMoveWidget(panel->attrFrm, 15, 50); - WMResizeWidget(panel->attrFrm, frame_width, 240); + WMMoveWidget(panel->attrFrm, 15, 45); + WMResizeWidget(panel->attrFrm, frame_width, 250); for (i=0; i < 10; i++) { char *caption = NULL; @@ -1166,10 +1176,10 @@ createInspectorForWindow(WWindow *wwin) /**** more attributes ****/ panel->moreFrm = WMCreateFrame(panel->win); WMSetFrameTitle(panel->moreFrm, _("Advanced")); - WMMoveWidget(panel->moreFrm, 15, 50); - WMResizeWidget(panel->moreFrm, frame_width, 240); + WMMoveWidget(panel->moreFrm, 15, 45); + WMResizeWidget(panel->moreFrm, frame_width, 250); - for (i=0; i < 7; i++) { + for (i=0; i < 8; i++) { char *caption = NULL; int flag = 0; @@ -1202,6 +1212,10 @@ createInspectorForWindow(WWindow *wwin) caption = _("Emulate Application Icon"); flag = WFLAGP(wwin, emulate_appicon); break; + case 7: + caption = _("Full Screen Maximization"); + flag = WFLAGP(wwin, full_maximize); + break; } panel->moreChk[i] = WMCreateSwitchButton(panel->moreFrm); WMMoveWidget(panel->moreChk[i], 10, 20*(i+1)); @@ -1212,7 +1226,7 @@ createInspectorForWindow(WWindow *wwin) panel->moreLbl = WMCreateLabel(panel->moreFrm); WMResizeWidget(panel->moreLbl, frame_width - (2 * 5), 60); - WMMoveWidget(panel->moreLbl, 5, 160); + WMMoveWidget(panel->moreLbl, 5, 180); WMSetLabelText(panel->moreLbl, _("Enable the \"Don't bind...\" options to allow the " "application to receive all mouse or keyboard events.")); diff --git a/src/winspector.h b/src/winspector.h index edf32590..e4eea096 100644 --- a/src/winspector.h +++ b/src/winspector.h @@ -60,7 +60,7 @@ typedef struct InspectorPanel { /* 3rd page. more attributes */ WMFrame *moreFrm; - WMButton *moreChk[7]; + WMButton *moreChk[8]; WMLabel *moreLbl; diff --git a/test/Makefile.in b/test/Makefile.in index 9c7ebf04..a7b9de5e 100644 --- a/test/Makefile.in +++ b/test/Makefile.in @@ -124,7 +124,7 @@ DIST_COMMON = Makefile.am Makefile.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best SOURCES = $(wtest_SOURCES) OBJECTS = $(wtest_OBJECTS) diff --git a/util/Makefile.am b/util/Makefile.am index 97e21d6d..1f378ece 100644 --- a/util/Makefile.am +++ b/util/Makefile.am @@ -5,9 +5,10 @@ pkgdatadir = $(datadir)/@PACKAGE@ bin_PROGRAMS = wxcopy wxpaste wdwrite getstyle setstyle seticons geticonset wmsetbg -bin_SCRIPTS = wmaker.inst wm-oldmenu2new wsetfont +bin_SCRIPTS = wmaker.inst wm-oldmenu2new wsetfont wkdemenu.pl -EXTRA_DIST = wmaker.inst.in bughint wm-oldmenu2new wsetfont directjpeg.c +EXTRA_DIST = wmaker.inst.in bughint wm-oldmenu2new wsetfont directjpeg.c \ + wkdemenu.pl INCLUDES = @DFLAGS@ -I$(top_srcdir)/wrlib @HEADER_SEARCH_PATH@ diff --git a/util/Makefile.in b/util/Makefile.in index 57b1be76..a3a68902 100644 --- a/util/Makefile.in +++ b/util/Makefile.in @@ -91,9 +91,10 @@ pkgdatadir = $(datadir)/@PACKAGE@ bin_PROGRAMS = wxcopy wxpaste wdwrite getstyle setstyle seticons geticonset wmsetbg -bin_SCRIPTS = wmaker.inst wm-oldmenu2new wsetfont +bin_SCRIPTS = wmaker.inst wm-oldmenu2new wsetfont wkdemenu.pl + +EXTRA_DIST = wmaker.inst.in bughint wm-oldmenu2new wsetfont directjpeg.c wkdemenu.pl -EXTRA_DIST = wmaker.inst.in bughint wm-oldmenu2new wsetfont directjpeg.c INCLUDES = @DFLAGS@ -I$(top_srcdir)/wrlib @HEADER_SEARCH_PATH@ @@ -184,7 +185,7 @@ DIST_COMMON = README Makefile.am Makefile.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best SOURCES = $(wxcopy_SOURCES) $(wxpaste_SOURCES) $(wdwrite_SOURCES) $(getstyle_SOURCES) $(setstyle_SOURCES) $(seticons_SOURCES) $(geticonset_SOURCES) $(wmsetbg_SOURCES) OBJECTS = $(wxcopy_OBJECTS) $(wxpaste_OBJECTS) $(wdwrite_OBJECTS) $(getstyle_OBJECTS) $(setstyle_OBJECTS) $(seticons_OBJECTS) $(geticonset_OBJECTS) $(wmsetbg_OBJECTS) diff --git a/util/README b/util/README index 5b764249..44e06e44 100644 --- a/util/README +++ b/util/README @@ -33,4 +33,4 @@ wdwrite- write data into the defaults database (configuration files). wsetfont- set locale the fonts needed for a specific locale for Window Maker -wkdemenu.sh- convert a KDE menu into a wmaker menu (for pipe) +wkdemenu.pl- convert a KDE menu into a wmaker menu (for pipe) diff --git a/util/setstyle.c b/util/setstyle.c index fac78e4f..73049ad6 100644 --- a/util/setstyle.c +++ b/util/setstyle.c @@ -303,8 +303,9 @@ main(int argc, char **argv) prop = PLGetProplistWithPath(path); if (!prop) { - printf("%s:could not load WindowMaker configuration file \"%s\".\n", - ProgName, path); + perror(path); + printf("%s:could not load WindowMaker configuration file.\n", + ProgName); exit(1); } @@ -345,8 +346,8 @@ main(int argc, char **argv) style = PLGetProplistWithPath(buffer); if (!style) { - printf("%s:could not load style file \"%s\".\n", ProgName, - buffer); + perror(buffer); + printf("%s:could not load style file.\n", ProgName); exit(1); } @@ -355,7 +356,8 @@ main(int argc, char **argv) } else { style = PLGetProplistWithPath(file); if (!style) { - printf("%s:could not load style file \"%s\".\n", ProgName, file); + perror(file); + printf("%s:could not load style file.\n", ProgName); exit(1); } } diff --git a/util/wmaker.inst.in b/util/wmaker.inst.in index 0c0384e9..7f7f2e7a 100644 --- a/util/wmaker.inst.in +++ b/util/wmaker.inst.in @@ -23,7 +23,7 @@ BINDIR="#bindir#" make_dir() { mkdir $1 - chmod +rw $1 + chmod +rwx $1 } make_script() { @@ -37,7 +37,7 @@ PATH="\$PATH:$BINDIR" # If you login from xdm, uncomment this to make error messages appear # in the console window. # -# tail -f $HOME/.xsession-errors > /dev/console +# tail -f $HOME/.xsession-errors > /dev/console & exec wmaker @@ -240,21 +240,14 @@ fi cp $GLOBALDIR/README.themes $GSDIR/Library/WindowMaker cp $GLOBALDIR/README $GSDIR/Library/WindowMaker -# xx herbert -if test -n "$BATCH"; then - test -f ~$GSDIR/Library/WindowMaker/autostart || \ + +test -f ~$GSDIR/Library/WindowMaker/autostart || \ cp $GLOBALDIR/autostart.sh $GSDIR/Library/WindowMaker/autostart - chmod +rx $GSDIR/Library/WindowMaker/autostart - test -f ~$GSDIR/Library/WindowMaker/exitscript || \ +chmod +rx $GSDIR/Library/WindowMaker/autostart + +test -f ~$GSDIR/Library/WindowMaker/exitscript || \ cp $GLOBALDIR/exitscript.sh $GSDIR/Library/WindowMaker/exitscript - chmod +rx $GSDIR/Library/WindowMaker/exitscript -else - cp -i $GLOBALDIR/autostart.sh $GSDIR/Library/WindowMaker/autostart - chmod +rx $GSDIR/Library/WindowMaker/autostart - cp -i $GLOBALDIR/exitscript.sh $GSDIR/Library/WindowMaker/exitscript - chmod +rx $GSDIR/Library/WindowMaker/exitscript -fi -# /xx herbert +chmod +rx $GSDIR/Library/WindowMaker/exitscript # xx herbert if test -n "$BATCH" ; then @@ -267,7 +260,7 @@ fi # ####################### -DATE=`date +%m%d%H%M` +DATE=`date +%b%d.%T` show_end_message() { @@ -286,13 +279,19 @@ else fi } -wmaker_found=1 +wmaker_found=0 for xinit in .xinitrc .Xclients .xsession; do test ! -f "$HOME/$xinit" && continue - test -z "`grep wmaker $HOME/$xinit`" - [ $? -eq 0 ] && wmaker_found=0 + res="`grep wmaker $HOME/$xinit`" + if test "x$res" != x; then + wmaker_found=1 + break + fi done -[ $wmaker_found -eq 1 ] && show_end_message && exit 0 +if test $wmaker_found = 1; then + show_end_message + exit 0 +fi trap "show_end_message;exit" 2 @@ -301,7 +300,8 @@ echo echo "Now the .xinitrc, .Xclients or .xsession script must be updated so that" echo "it calls wmaker when you start an X session." echo "Type the name of the file that must be changed (normally .xinitrc)." -echo "If the file already exists, it will be backed up with a .old.$DATE extension" +echo "If the file already exists, it will be backed up with a .old.$DATE " +echo "extension" echo "If you want to edit it by hand, hit -C now." read file diff --git a/util/wmsetbg.c b/util/wmsetbg.c index 37e519b9..95ba28e4 100644 --- a/util/wmsetbg.c +++ b/util/wmsetbg.c @@ -696,6 +696,12 @@ duplicatePixmap(Pixmap pixmap, int width, int height) } +static int +dummyErrorHandler(Display *dpy, XErrorEvent *err) +{ + return 0; +} + void setPixmapProperty(Pixmap pixmap) { @@ -717,7 +723,10 @@ setPixmapProperty(Pixmap pixmap) &type, &format, &length, &after, &data); if ((type == XA_PIXMAP) && (format == 32) && (length == 1)) { + XSetErrorHandler(dummyErrorHandler); XKillClient(dpy, *((Pixmap *)data)); + XSync(dpy, False); + XSetErrorHandler(NULL); mode = PropModeReplace; } else { mode = PropModeAppend; @@ -976,7 +985,6 @@ char* getPixmapPath(char *domain) { proplist_t val; - proplist_t d; char *ptr, *data; int len, i, count; @@ -1019,7 +1027,7 @@ getPixmapPath(char *domain) if (i>0) ptr--; *(ptr--) = 0; - PLRelease(d); + PLRelease(val); return data; } @@ -1118,7 +1126,6 @@ main(int argc, char **argv) char *texture = NULL; int workspace = -1; - signal(SIGINT, SIG_DFL); signal(SIGTERM, SIG_DFL); signal(SIGQUIT, SIG_DFL); @@ -1141,7 +1148,7 @@ main(int argc, char **argv) wfatal("too few arguments for %s\n", argv[i-1]); exit(1); } - display = argv[i+1]; + display = argv[i]; } else if (strcmp(argv[i], "-s")==0 || strcmp(argv[i], "--scale")==0) { style = "spixmap"; diff --git a/wmlib/Makefile.in b/wmlib/Makefile.in index 9673c5e6..d42b7f31 100644 --- a/wmlib/Makefile.in +++ b/wmlib/Makefile.in @@ -125,7 +125,7 @@ DIST_COMMON = COPYING.LIB Makefile.am Makefile.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best SOURCES = $(libWMaker_a_SOURCES) OBJECTS = $(libWMaker_a_OBJECTS) diff --git a/wmlib/app.c b/wmlib/app.c index 1d1c3346..f0c412f5 100644 --- a/wmlib/app.c +++ b/wmlib/app.c @@ -65,10 +65,10 @@ WMAppAddWindow(WMAppContext *app, Window window) if (!win) return False; - free(app->windows); - memcpy(win, app->windows, sizeof(Window)*app->win_count); + free(app->windows); + win[app->win_count] = window; app->windows = win; app->win_count++; diff --git a/wrlib/Makefile.am b/wrlib/Makefile.am index 1864acc3..f0bffd0b 100644 --- a/wrlib/Makefile.am +++ b/wrlib/Makefile.am @@ -4,7 +4,7 @@ AUTOMAKE_OPTIONS = no-dependencies lib_LTLIBRARIES = libwraster.la -libwraster_la_LDFLAGS = -version-info 1:3:0 +libwraster_la_LDFLAGS = -version-info 2:0:1 bin_SCRIPTS = get-wraster-flags diff --git a/wrlib/Makefile.in b/wrlib/Makefile.in index 625f5d33..dccf28f2 100644 --- a/wrlib/Makefile.in +++ b/wrlib/Makefile.in @@ -91,7 +91,7 @@ AUTOMAKE_OPTIONS = no-dependencies lib_LTLIBRARIES = libwraster.la -libwraster_la_LDFLAGS = -version-info 1:3:0 +libwraster_la_LDFLAGS = -version-info 2:0:1 bin_SCRIPTS = get-wraster-flags @@ -165,7 +165,7 @@ Makefile.in NEWS TODO alloca.c configure.in DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST) -TAR = tar +TAR = gtar GZIP_ENV = --best SOURCES = $(libwraster_la_SOURCES) $(testgrad_SOURCES) $(testdraw_SOURCES) $(view_SOURCES) OBJECTS = $(libwraster_la_OBJECTS) $(testgrad_OBJECTS) $(testdraw_OBJECTS) $(view_OBJECTS) diff --git a/wrlib/load.c b/wrlib/load.c index 0e736a25..041a36d3 100644 --- a/wrlib/load.c +++ b/wrlib/load.c @@ -100,18 +100,6 @@ extern RImage *RLoadGIF(RContext *context, char *file_name, int index); #endif -static char* -wstrdup(char *s) -{ - char *tmp; - - tmp = malloc(strlen(s)+1); - if (!tmp) - return NULL; - return strcpy(tmp, s); -} - - char** RSupportedFileFormats(void) { @@ -289,7 +277,40 @@ RLoadImage(RContext *context, char *file, int index) } +char* +RGetImageFileFormat(char *file) +{ + switch (identFile(file)) { + case IM_XPM: + return "XPM"; + +#ifdef USE_TIFF + case IM_TIFF: + return "TIFF"; +#endif /* USE_TIFF */ + +#ifdef USE_PNG + case IM_PNG: + return "PNG"; +#endif /* USE_PNG */ + +#ifdef USE_JPEG + case IM_JPEG: + return "JPEG"; +#endif /* USE_JPEG */ + +#ifdef USE_GIF + case IM_GIF: + return "GIF"; +#endif /* USE_GIF */ + + case IM_PPM: + return "PPM"; + default: + return NULL; + } +} static int diff --git a/wrlib/wraster.h b/wrlib/wraster.h index 04c8d9bf..b7a6835b 100644 --- a/wrlib/wraster.h +++ b/wrlib/wraster.h @@ -1,7 +1,7 @@ /* * Raster graphics library * - * Copyright (c) 1997, 1998 Alfredo K. Kojima + * Copyright (c) 1997, 1998, 1999 Alfredo K. Kojima * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public @@ -39,8 +39,8 @@ #define RLRASTER_H_ -/* version of the header for the library: 0.12 */ -#define WRASTER_HEADER_VERSION 12 +/* version of the header for the library: 0.13 */ +#define WRASTER_HEADER_VERSION 13 #include @@ -250,6 +250,9 @@ enum { */ char **RSupportedFileFormats(void); + +char *RGetImageFileFormat(char *file); + /* * Xlib contexts */ -- 2.11.4.GIT