On Thu, 06 Mar 2008 20:34:03 -0500 Dan Espen <[EMAIL PROTECTED]> wrote:
> =?ISO-8859-1?Q?Jes=FAs?= Guerrero <[EMAIL PROTECTED]> writes: > > On Fri, 7 Mar 2008 00:44:09 +0100 > > Jes=FAs Guerrero <[EMAIL PROTECTED]> wrote: > > > > Conditionals patch revised and attached. > > > > Is it valid? Does it lack something? > > > > My idea is to shorten the list of available patches as much as we can by=20 > > including those that are evidently clean, useful and harmless upstream. > > That way, we can ease the process for the rest of the patches. > > Except for not updating test cases (which almost no one is doing), > it looks clean and reasonable to me. I saw that file and plan to update it. I just need to watch into it to understand the logic of the thing. Feel free to give any advice if you feel that there's something relevant that I should know. For now, I have a preliminary versions with that file included. Attached. -- Jesús Guerrero <[EMAIL PROTECTED]>
diff -U5 -r fvwm/ChangeLog fvwm/ChangeLog --- fvwm/ChangeLog 2008-03-04 01:09:54.000000000 +0100 +++ fvwm/ChangeLog 2008-03-07 01:33:47.000000000 +0100 @@ -1,5 +1,13 @@ +2008-03-07 Jesús Guerrero <i92guboj(at)terra(dot)es> + + * fvwm/contitionals.c (CreateConditionMask): + add some conditional masks: HasTitle, HasBorders, + TitleAtBottom, TitleAtTop, TitleAtLeft, TitleAtRight + * doc/fvwm/conditionals.xml + documentation for the new conditions + 2008-02-29 Viktor Griph <griph(at)dd(dot)chalmers(dot)se> * fvwm/add_window.c (setup_frame_window): fix core dump with ARGB detection code fix compilation without XRender diff -U5 -r fvwm/doc/fvwm/conditionals.xml fvwm/doc/fvwm/conditionals.xml --- fvwm/doc/fvwm/conditionals.xml 2007-08-07 00:24:03.000000000 +0200 +++ fvwm/doc/fvwm/conditionals.xml 2008-03-07 01:33:06.000000000 +0100 @@ -187,11 +187,17 @@ <emphasis remap='I'>StickyAcrossPages</emphasis>, <emphasis remap='I'>StickyIcon</emphasis>, <emphasis remap='I'>StickyAcrossDesksIcon</emphasis>, <emphasis remap='I'>StickyAcrossPagesIcon</emphasis>, <emphasis remap='I'>Transient</emphasis>, -<emphasis remap='I'>Visible</emphasis>.</para> +<emphasis remap='I'>Visible</emphasis>, +<emphasis remap='I'>HasTitle</emphasis>, +<emphasis remap='I'>HasBorders</emphasis>, +<emphasis remap='I'>TitleAtBottom</emphasis>, +<emphasis remap='I'>TitleAtTop</emphasis>, +<emphasis remap='I'>TitleAtLeft</emphasis>, +<emphasis remap='I'>TitleAtRight</emphasis>.</para> <para>The <emphasis remap='I'>AcceptsFocus</emphasis> condition excludes all windows that do not want the input focus (the application has set the "Input hints" for the window to @@ -454,10 +460,23 @@ <emphasis remap='I'>Visible</emphasis> condition matches only windows that are at least partially visible on the current viewport and not completely overlapped by other windows.</para> +<para>The +<emphasis remap='I'>HasTitle</emphasis> +condition matches only windows that have a title bar.</para> + +<para>The +<emphasis remap='I'>HasBorders</emphasis> +condition matches only windows that have borders.</para> + +<para>The +<emphasis remap='I'>TitleAtBottom</emphasis>, <emphasis remap='I'>TitleAtTop</emphasis>, <emphasis remap='I'>TitleAtLeft</emphasis>, <emphasis remap='I'>TitleAtRight</emphasis>, +conditions matches respectively only windows that have a title +bar, and have it on the specified location.</para> + </section> </section> diff -U5 -r fvwm/fvwm/conditional.c fvwm/fvwm/conditional.c --- fvwm/fvwm/conditional.c 2007-10-06 11:17:09.000000000 +0200 +++ fvwm/fvwm/conditional.c 2008-03-07 01:10:54.000000000 +0100 @@ -598,10 +598,40 @@ else if (StrEquals(cond,"HasHandles")) { SET_HAS_HANDLES(mask, on); SETM_HAS_HANDLES(mask, 1); } + else if (StrEquals(cond, "HasTitle")) + { + SET_HAS_TITLE(mask, on); + SETM_HAS_TITLE(mask, 1); + } + else if (StrEquals(cond, "HasBorders")) + { + SET_HAS_NO_BORDER(mask, !on); + SETM_HAS_NO_BORDER(mask, 1); + } + else if (StrEquals(cond, "TitleAtBottom")) + { + SET_TITLE_DIR(mask, DIR_S); + SETM_TITLE_DIR(mask, 1); + } + else if (StrEquals(cond, "TitleAtTop")) + { + SET_TITLE_DIR(mask, DIR_N); + SETM_TITLE_DIR(mask, 1); + } + else if (StrEquals(cond, "TitleAtLeft")) + { + SET_TITLE_DIR(mask, DIR_W); + SETM_TITLE_DIR(mask, 1); + } + else if (StrEquals(cond, "TitleAtRight")) + { + SET_TITLE_DIR(mask, DIR_E); + SETM_TITLE_DIR(mask, 1); + } else if (StrEquals(cond,"Iconifiable")) { SET_IS_UNICONIFIABLE(mask, !on); SETM_IS_UNICONIFIABLE(mask, 1); } diff -U5 -r fvwm/NEWS fvwm/NEWS --- fvwm/NEWS 2008-03-04 01:09:54.000000000 +0100 +++ fvwm/NEWS 2008-03-07 01:50:47.000000000 +0100 @@ -3,10 +3,15 @@ ------------------------------------------------------------------- Changes in beta release 2.5.26 (not released yet) +* New features: + + - Added new condition masks: HasTitle, HasBorders, + TitleAtBottom, TitleAtTop, TitleAtLeft, TitleAtRight + * Bug fixes: - Fix crash in ARGB visual detection code - Fix compilation without XRender support diff -U5 -r fvwm/tests/purify/purify.fvwm2rc fvwm/tests/purify/purify.fvwm2rc --- fvwm/tests/purify/purify.fvwm2rc 2004-05-30 16:05:49.000000000 +0200 +++ fvwm/tests/purify/purify.fvwm2rc 2008-03-07 03:07:22.000000000 +0100 @@ -2826,10 +2826,22 @@ + I CurrentEchoFunc !CurrentGlobalPage + I CurrentEchoFunc CurrentPageAnyDesk + I CurrentEchoFunc !CurrentPageAnyDesk + I CurrentEchoFunc CurrentGlobalPageAnyDesk + I CurrentEchoFunc !CurrentGlobalPageAnyDesk + + I CurrentEchoFunc HasTitle + + I CurrentEchoFunc !HasTitle + + I CurrentEchoFunc HasBorders + + I CurrentEchoFunc !HasBorders + + I CurrentEchoFunc TitleAtBottom + + I CurrentEchoFunc !TitleAtBottom + + I CurrentEchoFunc TitleAtTop + + I CurrentEchoFunc !TitleAtTop + + I CurrentEchoFunc TitleAtLeft + + I CurrentEchoFunc !TitleAtLeft + + I CurrentEchoFunc TitleAtRight + + I CurrentEchoFunc !TitleAtRight # All test + I CurrentEchoFunc * \ !* \ window* \ window6 \ @@ -2893,11 +2905,23 @@ CurrentGlobalPage \ !CurrentGlobalPage \ CurrentPageAnyDesk \ !CurrentPageAnyDesk \ CurrentGlobalPageAnyDesk \ - !CurrentGlobalPageAnyDesk + !CurrentGlobalPageAnyDesk \ + HasTitle \ + !HasTitle \ + HasBorders \ + !HasBorders \ + TitleAtBottom \ + !TitleAtBottom \ + TitleAtTop \ + !TitleAtTop \ + TitleAtLeft \ + !TitleAtLeft \ + TitleAtRight \ + !TitleAtRight DestroyFunc DirectionEchoFunc AddToFunc DirectionEchoFunc + I Direction $* Nop + I KeepRc TestRc (Match) Echo Direction ($*) Match