Re: [compiz] compiz lists.freedesktop.org strangeness

2008-01-24 Thread Travis Watkins
On Jan 23, 2008 11:33 PM, David C. Rankin
[EMAIL PROTECTED] wrote:
 Quinn wrote:
  it seems we all did, or at least so did I
 

 Good to know. I just had to rebuild a server and it scared the hell out
 of me thinking that somehow Postfix was coughing up old messages


 --

 David C. Rankin, J.D., P.E.
 Rankin Law Firm, PLLC
 510 Ochiltree Street
 Nacogdoches, Texas 75961
 Telephone: (936) 715-9333
 Facsimile: (936) 715-9339
 www.rankinlawfirm.com
 ___
 compiz mailing list
 compiz@lists.freedesktop.org
 http://lists.freedesktop.org/mailman/listinfo/compiz



The messages were probably held in the moderation queue as they were
from people that weren't subscribed to the list. I guess someone
cleared the queue.


-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Python plugin (Python API for Compiz)

2008-01-23 Thread Travis Watkins
On 4/10/07, Mike Dransfield [EMAIL PROTECTED] wrote:
 Removing WRAP/UNWRAP totally seems virtually impossible
 without losing a lot of functionality.  If I make them just provide
 a named method then I have to check each plugins attributes
 one by one and they would still have to call unwrap/call/wrap
 themselves during the wrapped function.  Notice how inactive
 calls the core method at a specific point, that would be hard
 to do without the wrap function.

 If anyone has any ideas on making wrap/unwrap less
 complicated without removing the functionality then I would
 like to hear about it :)

In this case I see no reason why you couldn't UNWRAP immediately and
WRAP at the end of the method so having the C side do it for you would
still work. Anyway, the wrap/unwrap methods could still be available
for special cases but I can't think of a time when automatically doing
it at the start and end of a method would ever limit you.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] fonts unreadable on resize

2007-12-28 Thread Travis Watkins
On Dec 28, 2007 4:51 PM, Bill Moseley [EMAIL PROTECTED] wrote:
 I have the Resize info feature enabled on my desktop and on my
 laptop both running Gutsy.

 on the desktop the fonts are impossible to read:

 http://hank.org/resize.png

 but are very clear on the laptop.

 And tips to fix?



You have a broken cairo (and are most likely using Ubuntu or Mandriva)
and cannot use VBGR subpixel order.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Correcting the number of virtual desktops

2007-11-18 Thread Travis Watkins
On Nov 18, 2007 2:45 PM, Markus Elfring [EMAIL PROTECTED] wrote:
 Hello,

 I have activated Compiz Fusion KDE 0.6.2-3.1 on my openSUSE 10.3 system. I was
 surprised by an increased number of desktops in the switcher applet of the KDE
 control bar. Now I wonder why there are still eight buttons offered despite I
 have reduced the setting Number of desktops to two.

 The value 6 will result in 24 buttons. In which source file is the 
 unexpected
 formula count * 4 applied?

 Regards,
 Markus


You have 4 viewports (probably for cube). So 2 workspaces each with 4
viewports is 8 and so on. Set number of desktops to 1 and things
should work.


-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] CVE-2007-3920

2007-11-06 Thread Travis Watkins
On 11/6/07, Colin Guthrie [EMAIL PROTECTED] wrote:
 Hanno Böck wrote:
  A bypass for screensaver password dialogs has been found within compiz.
 
  What about it?
  Ubuntu created a patch, gentoo took the same:
  https://bugs.gentoo.org/show_bug.cgi?id=196878

 I'm no expert in these matter, but is hard coding gnome-screensaver
 into compiz the right solution for this problem? Would KDE's
 screensaver or xscreensaver suffer from similar problems that this fix
 doesn't address?

 Perhaps the first hunk of the patch catches these cases? Can you shed a
 little light on it for the benefit of the cranially challenged? ;)


Actually the problem is in gnome-screensaver, compiz (really
XCompositeUnredirectWindow) just exposes it. The patch to compiz was
just the quickest solution until someone can make gnome-screensaver
not do bad things.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] memory leak bug under ubuntu gutsy w/ nvidia

2007-10-20 Thread Travis Watkins
On 10/19/07, Matt Price [EMAIL PROTECTED] wrote:
 hi there,

 a number of users of ubuntu gutsy with nvidia cards are experiencing a
 serious memory leak under compiz.  This leak essentially renders compiz
 unusable for us.  Gutsy ships with a compiz versioned at 0.6.0
 +git20071008 , which I imagine isn't that different from the current
 compiz, and with the current 100.14.19 nvidia driver running under a
 2.6.22 kernel.  I'm just wondering whether any non-ubuntu users are
 seeing this same problem, and whether anyone on this list has
 suggestions for tracking down the bug source.  At first it seemed that
 the bug might be specific to some plugin, but that doesn't seem to be
 the case.

 The ubuntu bug report is at :
 https://bugs.launchpad.net/ubuntu/+source/compiz-fusion-plugins-main/+bug/151168

 with at least one duplicate at:
 https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/154210

   thanks for the help,

 matt


It's the problem with the nvidia driver. Instead of showing you a
black window when it runs out of memory it sticks the texture in the
process asking for it and never frees it. This is our latest guess,
anyway.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Video plugin and patched MPlayer

2007-10-14 Thread Travis Watkins
On 10/13/07, jayan cabatuan [EMAIL PROTECTED] wrote:
 Hey guys,
 I managed to patch mplayer and Xgl to use the video plugin. The video
 plays but the window is just white. I can see the silhouette of the
 people in the video when I make it transparent.
 Do you guys have any idea? Am I missing a step? Can anyone shed any
 light on my situation? Thanks.
 Here is the output:

 [EMAIL PROTECTED] ~]$ /opt/bin/mplayer -v
 Videos/Jordan/Michael.Jordan.-.Ultimate.Jordan.avi | grep compiz
 mplayer: could not connect to socket
 mplayer: No such file or directory
 Failed to open LIRC support. You will not be able to use your remote control.
 Xlib:  extension XFree86-VidModeExtension missing on display :1.0.
 [xv] Detected wm supports compiz video.
 [AO OSS] audio_setup: Can't open audio device /dev/dsp: Device or resource 
 busy
 [xv] using compiz composited yv12 output
 [xv] Detected wm supports compiz video.1 1208/1208  8%  1%  0.8% 0 0 49%
 [xv] using compiz composited yv12 output



Disable yv12 colorspace support in the video plugin.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] More clear CCSM messages

2007-09-17 Thread Travis Watkins
On 9/17/07, Vadim Peretokin [EMAIL PROTECTED] wrote:
 Hello,

 Would it be possible to have someone knowledgeable about the inner working
 of Compiz to change the messages CCSM uses ( which can be found here) to be
 understandable to us not really technical people?

 One example would be the 'Sync To VBlank' option. I have no idea what VBlank
 is, so how, what will sync to it, I have no idea. Checking the tooltip,
 'Only perform screen updates during vertical blanking period', I know now
 that sync means a screen update, but what's a vertical blanking period then?

 Would be great if someone helped make ccsm more clear :)


CCSM is not meant to be an end-user tool. :) If you don't know what
these things are you should have no reason to change them.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] OSD Mystery

2007-08-31 Thread Travis Watkins
On 8/31/07, David Abrahams [EMAIL PROTECTED] wrote:

 on Thu Aug 30 2007, Travis Watkins amaranth-AT-ubuntu.com wrote:

  Maybe this is just a hidden gnome setting.  Does anybody know?
 
 
  This is gnome-settings-daemon. In the version of GNOME you're using it
  only does the composited check when it starts so you either have to
  start compiz before gnome-settings-daemon or kill
  gnome-settings-daemon after starting compiz (it'll restart on it's
  own).

 Thanks; it's back.  I guess its disappearance was just due to
 restarting compiz at some point.  Is there a way to hook compiz
 startup so it always kills gnome-settings-daemon ?


I wouldn't bother, in GNOME 2.20 it does this check before the OSD is
shown so it updates appropriately when you turn compiz on/off.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] OSD Mystery

2007-08-30 Thread Travis Watkins
On 8/30/07, David Abrahams [EMAIL PROTECTED] wrote:

 I recently started using compiz-fusion.  After spending months looking
 at an anemic little rectangular on-screen volume control when I use
 the volume buttons on my ubuntu thinkpad T60p, all of a sudden I
 noticed that I was getting a nice, big, robust rounded-corner display
 (somewhat mac-like).  Now it's gone again.

 I really have no clue whether this came from compiz-fusion, emerald, a
 plugin, or something else entirely.  I've been unable to find any
 likely options in the ccsm.  I was using prebuilt compiz-fusion
 packages from amaranths repo for a while, and just switched to one I
 built from git-head.  I don't know if that accounts for the
 disappearance.

 Maybe this is just a hidden gnome setting.  Does anybody know?


This is gnome-settings-daemon. In the version of GNOME you're using it
only does the composited check when it starts so you either have to
start compiz before gnome-settings-daemon or kill
gnome-settings-daemon after starting compiz (it'll restart on it's
own).

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] [ANNOUNCE] compiz-0.5.2

2007-08-08 Thread Travis Watkins
On 8/7/07, Colin Guthrie [EMAIL PROTECTED] wrote:
 David Reveman wrote:
  On Tue, 2007-08-07 at 19:35 +0200, dragoran wrote:
 
  On 8/3/07, David Reveman [EMAIL PROTECTED] wrote:
  A new compiz release 0.5.2 is now available
 
  any chance for a 0.6.0 release before 2007/08/28 ?
  (fedora 8 feature freeze)
 
  I wont have time but we could create a 0.6 branch for this if a some
  people are interested in working on it.

 The Mandriva release cycle seems to be harmonious to Fedora's dates. So
 this is just another +1 on the 0.6 release plan :)


Ubuntu's freeze is a little closer (Aug 16th) but +1 here too. We can
always try to get an exception. :)

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Dual-screen compiz mostly working

2007-08-03 Thread Travis Watkins
On 8/3/07, Mick Semb Wever [EMAIL PROTECTED] wrote:
 On Wed, 01 Aug 2007 12:03:30 +0200, Michel Dänzer wrote:

   - my second screen doesn't render properly. Compiz events cause it to
  redraw but application events do not cause a redraw! This is a
  showstopper for me so i'm still using metacity when in dual- screen
  setup.
 
  That sounds weird, can you create screenshots or something to illustrate
  the problem?

 I've got some video captures of the problem:
 http://wever.org/compiz-dualscreen-horizontal-3000x1200.ogg
 http://wever.org/compiz-dualscreen-vertical-1600x2250.ogg
 http://wever.org/compiz-dualscreen-vertical-1400x1818.ogg

 For horizontal-3000x1200, you can see the both compiz and applications
 events are accurately redrawn on the first monitor, but only compiz
 events are redrawn on the second monitor.

 For vertical-1600x2250, which also exceeds the 2048x2048 texture
 limitation, the same is true although a part of the second monitor
 redraws both ok.

 For vertical-1400x1818, which should be within the texture limitation, a
 similar result to vertical-1600x2250 occurs where only a part of the
 second monitor is redrawn.

 Some extra oddities:
  - this texture buffer, or atleast the rectangle covering both screens
 that redraws correctly, seems to change depending on the screen
 resolutions, ie it isn't fixed to 2048x2048,
  - never in dual-screen is my nautilus background rendered, except
 through the application-transparency of the gterm window,
  - even in single-screen sometimes the desktop background (infact
 everything but the current window) flashes black, i've seen this happen
 when an icon in gnome's system tray is blinking,
  - even in single-screen sometimes windows (more often maximised windows)
 just appear black or with the full desktop's background rendered within
 the window. When the background is rendered in the window instead of the
 application's contents the background is live regarding any changes to
 the real desktop background.

 ~mck



Increase the memory for the video chip in your BIOS.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Dual-screen compiz mostly working

2007-08-01 Thread Travis Watkins
On 8/1/07, Mick Semb Wever [EMAIL PROTECTED] wrote:
 I have dual-screen compiz-fusion finally working on my ATI Radeon
 Mobility X600.
 AIGLX was the way to go using MergedFB.

 gentoo linux-2.6.22
 x11-base/xorg-server-1.2.0-r3
 x11-base/xorg-x11-7.2
 media-libs/mesa-6.5.2-r1
 x11-wm/compiz-
 x11-wm/compiz-fusion-


 But a number of remaining issues:

  - my second screen doesn't render properly. Compiz events cause it to
 redraw but application events do not cause a redraw!
 This is a showstopper for me so i'm still using metacity when in dual-
 screen setup.
 I tried all sorts of tweaks onto my xorg.conf but nothing seemed to work.
 I thought it was maybe DynamicClocks but turning it to off didn't help.
 Do any of the compiz gurus know what might be at fault here or what i
 might do to provide better information on the bug?

  - my screens must be vertically positioned. Compiz doesn't render the
 full width when the screens are side by side. Even when vertically
 position i cannot have the second screen at 1600x1400 for the same reason.
 Is this a limitation of compiz? Are there plans to fix/improve it?

  - my nautilus background ( desktop icons) disappear replaced with the
 partially transparent cube. I haven't quite pinned down what causes this
 but it does very rarely also occur on single-screen setup. Opening more
 applications seems to aggravate it occurring, and so does the Reflection
 plugin.

  - my fonts are not nearly as clean and crisp under compiz as they are
 under metacity. It's like the fonts are thick and fuzzy under compiz.
 (I'm sure there's a correct terminology for that but i'm no expert).

 any help would be greatly appreciated!

 ~mck



Most of these problems are all the same problem, from the look of it.
Your screen resolution is higher than your video card's maximum
texture size. This is simply a hardware limitation. Compiz could do a
workaround for it but it'd be slow.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Blur problems

2007-07-17 Thread Travis Watkins
On 7/17/07, Dario Zanzico [EMAIL PROTECTED] wrote:
 I'm using compiz compiled for feisty by trevino, on a mobility radeon x1600
 using fglrx 8.38.6 over Xgl 7.2.0.
 I'm experiencing some problems with the blur: after a short time using
 compiz the blur over
 the windows (most noticeably the terminal) becomes a opaque gray. I really
 don't know how to debug this problem... :(
 I'll be happy to give any information you'll need

 DisgustingAngel

 ___
 compiz mailing list
 compiz@lists.freedesktop.org
 http://lists.freedesktop.org/mailman/listinfo/compiz



Disable the video plugin and restart compiz. For some reason with Xgl
it seems to break alpha.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] Scale Binding

2007-06-07 Thread Travis Watkins
On 6/7/07, Andres Blanco [EMAIL PROTECTED] wrote:
 How about ctrl+ shift + arrows?


But other WMs use Ctrl-Alt-Up/Down/Left/Right too. Unneeded
inconsistency is bad.

-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] xsltproc, schemas.xslt

2007-05-14 Thread Travis Watkins
On 5/14/07, David Reveman [EMAIL PROTECTED] wrote:
 libxslt.pkg seem to be the pkg-config file we need to check for. I've
 updated configure.ac. Is this accurate with how ubuntu packages
 xsltproc?

No, having libxslt.pc does not guarantee xsltproc will be installed.
You have to actually check for the binary like my patch does.


 - David




-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] xsltproc, schemas.xslt

2007-05-11 Thread Travis Watkins
On 5/11/07, David Reveman [EMAIL PROTECTED] wrote:
 On Fri, 2007-05-11 at 15:31 +0200, Travis Watkins wrote:
  It seems like a build dependency on xsltproc was added but not checked
  for in the build system. I have a patch (attached) to fix this.

 I though the check for libxml-2.0 would guarantee that xsltproc exists.

In ubuntu we have a separate xsltproc package.


 
  Also, the schemas.xslt file does not seem to be copied into the build
  dir so the build fails. I have not been able to figure this one out
  yet.

 I think this should be fixed now.

Indeed, the schemas.xslt file seems to be installed correctly now.
Unfortunately mkinstalldirs seems to get overwritten as a broken
symlink to config/mkinstalldirs now. Will try to figure it out but I'm
not even sure where to start.


 - David




-- 
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] adding XCB dependency

2007-04-27 Thread Travis Watkins

On 4/27/07, Matt Russell [EMAIL PROTECTED] wrote:

XCB is included in the official repository in Ubuntu Feisty, but not
installed by default.


Worse, xlib in Ubuntu 7.04 does not use XCB so it's all or nothing,
you can't mix the two. Ubuntu 7.10 will have this though.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


[compiz] glu dependency

2007-04-25 Thread Travis Watkins

The following commit seems to have added a dependency on glu but does
no checks to see if it is actually available:

commit fa5bf5754d8a2e47d659a3abe5cb59a7b0e304d7
Author: David Reveman [EMAIL PROTECTED]
Date:   Tue Jan 16 06:07:39 2007 +0100

   Project vertices and only update minimum required destination texture
   region. Some more optimizations should be done here but the current
   changes should still give a major performance improvement.


My autofoo is very much lacking so I'm not sure how to add such a check.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-04-01 Thread Travis Watkins

On 4/1/07, Mike Dransfield [EMAIL PROTECTED] wrote:

My plan is to push these changes out and then quickly work
another patch to make it all work properly again.

Are you OK with this?




Sounds good, I'll be glad to finally get it committed. :)

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] re-work option initialization

2007-03-29 Thread Travis Watkins

On 3/29/07, Mike Dransfield [EMAIL PROTECTED] wrote:

 2. No convenient way to get the initial value of an option once it's
 been modified.


No, this was my problem when writing ini.

The way I see it is that gconf should be able to revert to
the default easily, ini might need some work.


I can't get the default value from dbus either.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-03-28 Thread Travis Watkins

On 3/27/07, David Reveman [EMAIL PROTECTED] wrote:

I told Mike Dransfield to have a look at your patches and include them
if they're OK. Let me know if you need feedback from me.



I keep updating and expecting them to be there. :) Mike didn't seem to
have any problems with them other than the harmless warnings from
dbus.

Mike, is there any reason these patches can't go in?

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-03-28 Thread Travis Watkins

On 3/28/07, Mike Dransfield [EMAIL PROTECTED] wrote:

I haven't forgotten about the patches, the problem
with the warning seems to point to a deeper problem
where the plugins are not correctly unregistered.
Have you looked any further into these warnings and
stopping them?



As explained, it's because when the dbus plugin loads it registers all
the plugins you have installed but it also registers plugins as
they're loaded so you get warnings about the 'allscreens' and
'screen0' paths being registered again. It doesn't hurt anything. If
dbus was last in your active_plugins you wouldn't get these messages.


Also I have been using the patches for the last week
and I am getting crashes in the unload function.  I
haven't had a chance to get to the bottom of it yet.



This I haven't seen, I'd have to get a backtrace from you.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


[compiz] moveWindowToViewportPosition only does horizontal viewports

2007-03-19 Thread Travis Watkins

As the subject says, moveWindowToViewportPosition only takes an x
argument. Shouldn't it have a y argument too for vertical viewports?

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-03-05 Thread Travis Watkins

On 3/5/07, David Reveman [EMAIL PROTECTED] wrote:

I haven't looked at it yet. I will soon. If all the functionality that
the current dbus plugin provides works OK, then I don't see any reason
for holding back on this one.


Should I add mikedee's changes? They change the interface for
activate. If you want I can add that and then split the patch into
pieces.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] CompDisplay from loaderLoadPlugin

2007-03-05 Thread Travis Watkins

On 3/5/07, David Reveman [EMAIL PROTECTED] wrote:

Wrap setDisplayOption and track changes to the active_plugins option.
That will let you know when a plugin gets loaded or unloaded.



That's what I was doing originally but then you have to keep a copy of
the active_changes list around and compare old to new. Wrapping
initPluginFor(Display|Screen) works fine though.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] decoration mask

2007-03-05 Thread Travis Watkins

On 3/5/07, David Reveman [EMAIL PROTECTED] wrote:

Some of my plans for the drawing infrastructure in compiz will solve
this problem nicely so if we can live without it for now, I'd be happy.



We seem to be able to work around it for now, dunno why it's needed in
beryl actually.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-03-04 Thread Travis Watkins

On 3/1/07, Travis Watkins [EMAIL PROTECTED] wrote:

Remaining problems:
  * need to figure out what to do with activate/deactivate
  * core doesn't get any options registered



Updated the patch. It now registers/unregisters plugins on load/unload
by wrapping initPluginForDisplay and friends. I also cleaned the code
up a bit.

Known problems:
 * still don't know what to do with activate/deactivate
 * had to comment out a couple free()s in my added code to make it
work, dunno why

Please comment.

--
Travis Watkins
http://www.realistanew.com
diff --git a/configure.ac b/configure.ac
index 4d71729..7010690 100644
--- a/configure.ac
+++ b/configure.ac
@@ -171,7 +171,7 @@ AC_ARG_ENABLE(dbus,
   [use_dbus=$enableval], [use_dbus=yes])
 
 if test x$use_dbus = xyes; then
-  PKG_CHECK_MODULES(DBUS, dbus-1, [use_dbus=yes], [use_dbus=no])
+  PKG_CHECK_MODULES(DBUS, dbus-1 libxml-2.0, [use_dbus=yes], [use_dbus=no])
 fi
 
 AM_CONDITIONAL(DBUS_PLUGIN, test x$use_dbus = xyes)
diff --git a/plugins/dbus.c b/plugins/dbus.c
index 782ad24..40ffdf1 100644
--- a/plugins/dbus.c
+++ b/plugins/dbus.c
@@ -29,10 +29,13 @@
 
 #define DBUS_API_SUBJECT_TO_CHANGE
 #include dbus/dbus.h
+#include libxml/xmlwriter.h
 
 #include compiz.h
 
 #define COMPIZ_DBUS_SERVICE_NAME	org.freedesktop.compiz
+#define COMPIZ_DBUS_INTERFACE			org.freedesktop.compiz
+#define COMPIZ_DBUS_ROOT_PATH			/org/freedesktop/compiz
 
 #define COMPIZ_DBUS_ACTIVATE_MEMBER_NAMEactivate
 #define COMPIZ_DBUS_DEACTIVATE_MEMBER_NAME  deactivate
@@ -71,13 +74,28 @@ typedef struct _DbusDisplay {
 
 SetDisplayOptionProc	  setDisplayOption;
 SetDisplayOptionForPluginProc setDisplayOptionForPlugin;
+
+InitPluginForDisplayProc initPluginForDisplay;
+FiniPluginForDisplayProc finiPluginForDisplay;
 } DbusDisplay;
 
 typedef struct _DbusScreen {
 SetScreenOptionProc		 setScreenOption;
 SetScreenOptionForPluginProc setScreenOptionForPlugin;
+
+InitPluginForScreenProc initPluginForScreen;
+FiniPluginForScreenProc finiPluginForScreen;
 } DbusScreen;
 
+static DBusHandlerResult dbusHandleMessage (DBusConnection *,
+	DBusMessage *,
+	void *);
+
+static DBusObjectPathVTable dbus_messages_vtable = {
+NULL, dbusHandleMessage, /* handler function */
+NULL, NULL, NULL, NULL
+};
+
 #define GET_DBUS_DISPLAY(d) \
 ((DbusDisplay *) (d)-privates[displayPrivateIndex].ptr)
 
@@ -104,7 +122,7 @@ dbusGetOptionsFromPath (CompDisplay *d,
 	int screenNum;
 
 	if (sscanf (path[1], screen%d, screenNum) != 1)
-	return FALSE;
+	return NULL;
 
 	for (s = d-screens; s; s = s-next)
 	if (s-screenNum == screenNum)
@@ -150,6 +168,487 @@ dbusGetOptionsFromPath (CompDisplay *d,
 return NULL;
 }
 
+/* functions to create introspection XML */
+static void
+dbusIntrospectStartInterface (xmlTextWriterPtr writer)
+{
+	xmlTextWriterStartElement (writer, BAD_CAST interface);
+	xmlTextWriterWriteAttribute (writer, BAD_CAST name,
+ BAD_CAST COMPIZ_DBUS_SERVICE_NAME);
+}
+
+static void
+dbusIntrospectEndInterface (xmlTextWriterPtr writer)
+{
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectAddArgument (xmlTextWriterPtr writer, char *type, char *direction)
+{
+xmlTextWriterStartElement (writer, BAD_CAST arg);
+xmlTextWriterWriteAttribute (writer, BAD_CAST type, BAD_CAST type);
+xmlTextWriterWriteAttribute (writer, BAD_CAST direction,
+ BAD_CAST direction);
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectAddMethod (xmlTextWriterPtr writer, char *name, int nArgs, ...)
+{
+va_list var_args;
+char *type, *direction;
+
+xmlTextWriterStartElement (writer, BAD_CAST method);
+xmlTextWriterWriteAttribute (writer, BAD_CAST name, BAD_CAST name);
+
+va_start (var_args, nArgs);
+while (nArgs)
+{
+	type = va_arg (var_args, char *);
+	direction = va_arg (var_args, char *);
+	dbusIntrospectAddArgument (writer, type, direction);
+	nArgs--;
+}
+va_end (var_args);
+
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectAddSignal (xmlTextWriterPtr writer, char *name, int nArgs, ...)
+{
+va_list var_args;
+char *type;
+
+xmlTextWriterStartElement (writer, BAD_CAST signal);
+xmlTextWriterWriteAttribute (writer, BAD_CAST name, BAD_CAST name);
+
+va_start (var_args, nArgs);
+while (nArgs)
+{
+	type = va_arg (var_args, char *);
+	dbusIntrospectAddArgument (writer, type, out);
+	nArgs--;
+}
+va_end (var_args);
+
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectAddNode (xmlTextWriterPtr writer, char *name)
+{
+xmlTextWriterStartElement (writer, BAD_CAST node);
+xmlTextWriterWriteAttribute (writer, BAD_CAST name, BAD_CAST name);
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectStartRoot (xmlTextWriterPtr writer)
+{
+xmlTextWriterStartElement (writer, BAD_CAST node);
+
+xmlTextWriterStartElement (writer

Re: [compiz] CompDisplay from loaderLoadPlugin

2007-03-03 Thread Travis Watkins

On 3/3/07, Mike Dransfield [EMAIL PROTECTED] wrote:

Could you wrap initPluginForDisplay/Screen instead?

This will give you the correct structures plus it will enable
the right number of screen option objects at the right time



Awesome, that looks perfect.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


[compiz] CompDisplay from loaderLoadPlugin

2007-03-02 Thread Travis Watkins

I'm trying to use custom functions for loaderLoadPlugin and
loaderUnloadPlugin to register/unregister plugin paths in the dbus
plugin as needed but I need to get access to a CompDisplay or
DbusDisplay in order to do so. Is there any way to get access to this?

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


[compiz] decoration mask

2007-03-01 Thread Travis Watkins

Beryl has this mask called PAINT_WINDOW_DECORATION_MASK that the
decoration plugin sets when it's drawing the decorator windows. It
lets you apply an effect to a window that doesn't affect the
decorations. Does this sound like something that would be useful in
compiz?

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-02-28 Thread Travis Watkins

On 2/27/07, Mike Dransfield [EMAIL PROTECTED] wrote:

I have had a quick look and I think its possible to have a
variant number of key value pairs with something like this
as the signature.

a(sv)

Which is probably the same as something like this (but will
probably not marshall as well)

a{sv}

Does this sound about right?


No, variant type means the value includes it's type info in itself.
it's not a catchall of any sort.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-02-28 Thread Travis Watkins

On 2/27/07, Travis Watkins [EMAIL PROTECTED] wrote:

Alright, I'll redo it as an addition to the current dbus plugin and
send in a patch. It might not be until tomorrow though.



Alright, here is my patch. A couple issues:
 * It doesn't seem to register any options for core,
dbusGetOptionsFromPath is failing for some reason
 * it doesn't include introspection for signals as I wasn't quite
sure where they belong
 * It doesn't register/unregister plugins and their screens/options
when you change active_plugins, it should do so
 * It probably leaks like a sieve :)

Also, it needs libxml2 but I wasn't sure how to include this in the
build system. I was doing my work with the standalone Makefile we use
for ported beryl plugins.

--
Travis Watkins
http://www.realistanew.com
diff --git a/plugins/dbus.c b/plugins/dbus.c
index 6fbb2e2..06e813a 100644
--- a/plugins/dbus.c
+++ b/plugins/dbus.c
@@ -29,10 +29,13 @@
 
 #define DBUS_API_SUBJECT_TO_CHANGE
 #include dbus/dbus.h
+#include libxml/xmlwriter.h
 
 #include compiz.h
 
 #define COMPIZ_DBUS_SERVICE_NAME	org.freedesktop.compiz
+#define COMPIZ_DBUS_INTERFACE			org.freedesktop.compiz
+#define COMPIZ_DBUS_ROOT_PATH			/org/freedesktop/compiz
 
 #define COMPIZ_DBUS_ACTIVATE_MEMBER_NAMEactivate
 #define COMPIZ_DBUS_DEACTIVATE_MEMBER_NAME  deactivate
@@ -78,6 +81,15 @@ typedef struct _DbusScreen {
 SetScreenOptionForPluginProc setScreenOptionForPlugin;
 } DbusScreen;
 
+static DBusHandlerResult dbusHandleMessage (DBusConnection *,
+	DBusMessage *,
+	void *);
+
+static DBusObjectPathVTable dbus_messages_vtable = {
+NULL, dbusHandleMessage, /* handler function */
+NULL, NULL, NULL, NULL
+};
+
 #define GET_DBUS_DISPLAY(d) \
 ((DbusDisplay *) (d)-privates[displayPrivateIndex].ptr)
 
@@ -150,6 +162,488 @@ dbusGetOptionsFromPath (CompDisplay *d,
 return NULL;
 }
 
+/* functions to create introspection XML */
+static void
+dbusIntrospectStartInterface (xmlTextWriterPtr writer)
+{
+	xmlTextWriterStartElement (writer, BAD_CAST interface);
+	xmlTextWriterWriteAttribute (writer, BAD_CAST name,
+ BAD_CAST COMPIZ_DBUS_SERVICE_NAME);
+}
+
+static void
+dbusIntrospectEndInterface (xmlTextWriterPtr writer)
+{
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectAddArgument (xmlTextWriterPtr writer, char *type, char *direction)
+{
+xmlTextWriterStartElement (writer, BAD_CAST arg);
+xmlTextWriterWriteAttribute (writer, BAD_CAST type, BAD_CAST type);
+xmlTextWriterWriteAttribute (writer, BAD_CAST direction,
+ BAD_CAST direction);
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectAddMethod (xmlTextWriterPtr writer, char *name, int nArgs, ...)
+{
+va_list var_args;
+char *type, *direction;
+
+xmlTextWriterStartElement (writer, BAD_CAST method);
+xmlTextWriterWriteAttribute (writer, BAD_CAST name, BAD_CAST name);
+
+va_start (var_args, nArgs);
+while (nArgs)
+{
+	type = va_arg (var_args, char *);
+	direction = va_arg (var_args, char *);
+	dbusIntrospectAddArgument (writer, type, direction);
+	nArgs--;
+}
+va_end (var_args);
+
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectAddSignal (xmlTextWriterPtr writer, char *name, int nArgs, ...)
+{
+va_list var_args;
+char *type;
+
+xmlTextWriterStartElement (writer, BAD_CAST signal);
+xmlTextWriterWriteAttribute (writer, BAD_CAST name, BAD_CAST name);
+
+va_start (var_args, nArgs);
+while (nArgs)
+{
+	type = va_arg (var_args, char *);
+	dbusIntrospectAddArgument (writer, type, out);
+	nArgs--;
+}
+va_end (var_args);
+
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectAddNode (xmlTextWriterPtr writer, char *name)
+{
+xmlTextWriterStartElement (writer, BAD_CAST node);
+xmlTextWriterWriteAttribute (writer, BAD_CAST name, BAD_CAST name);
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectStartRoot (xmlTextWriterPtr writer)
+{
+xmlTextWriterStartElement (writer, BAD_CAST node);
+
+xmlTextWriterStartElement (writer, BAD_CAST interface);
+xmlTextWriterWriteAttribute (writer, BAD_CAST name,
+ BAD_CAST org.freedesktop.DBus.Introspectable);
+
+dbusIntrospectAddMethod (writer, Introspect, 1, s, out);
+
+xmlTextWriterEndElement (writer);
+}
+
+static void
+dbusIntrospectEndRoot (xmlTextWriterPtr writer)
+{
+xmlTextWriterEndDocument (writer);
+}
+
+/* introspection handlers */
+static Bool
+dbusHandleRootIntrospectMessage (DBusConnection *connection,
+ DBusMessage*message,
+ CompDisplay	*d)
+{
+char **plugins, **plugin_name;
+int nPlugins;
+
+xmlTextWriterPtr writer;
+xmlBufferPtr buf;
+
+buf = xmlBufferCreate ();
+writer = xmlNewTextWriterMemory (buf, 0);
+
+dbusIntrospectStartRoot (writer);
+dbusIntrospectStartInterface (writer);
+
+dbusIntrospectAddMethod (writer

Re: [compiz] dbus introspection

2007-02-27 Thread Travis Watkins

On 2/27/07, David Reveman [EMAIL PROTECTED] wrote:

Incremental changes are always appreciated when possible. Having a
history of all changes is always good. You can do that locally or we can
get things into head in its current state and you can work on it there.
Whatever you prefer. If the changes can't be done incrementally then it
doesn't matter much.


Alright, I'll redo it as an addition to the current dbus plugin and
send in a patch. It might not be until tomorrow though.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-02-26 Thread Travis Watkins

On 2/26/07, David Reveman [EMAIL PROTECTED] wrote:

Awesome, I've been hoping that someone would interested in doing this.


The new dbus-python requires it so if I want to write python apps that
use it this is needed. :)


I'm all for changing the API. If you like to get your current changes in
right now we should do that, though.


Alright, it might take me a day or so to clean it up. I've already
made some API changes in my local copy. Also, I started it as a new
plugin instead of patching the current dbus plugin because I thought
I'd have to make a lot of changes.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


Re: [compiz] dbus introspection

2007-02-26 Thread Travis Watkins

On 2/26/07, Mike Dransfield [EMAIL PROTECTED] wrote:

I thought that we were ok for most options because
each method is attached to a different object.
You should be able to read each option to tell what
datatype it is when generating the XML, or am I
misunderstanding it?


You're right, I forgot about that. The current API for this will work fine.


The real problem is actions (ie activate/terminate)
because they can take a variable number of arguments
so would need to register somehow.


Perhaps it can take an array?

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


[compiz] Re: [PATCH] dbus list option as array - was: DBus setting options broken

2007-01-26 Thread Travis Watkins

On 1/26/07, David Reveman [EMAIL PROTECTED] wrote:

Looks good. I updated the example in comment above the function that you
changed and pushed it out.


Works great! Thanks guys.

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


[compiz] Freenode Group Registration

2006-12-21 Thread Travis Watkins

I've been informed by freenode staff that in order to claim #compiz
and #compiz-dev (both are apparently leftovers from beryl) we need to
fill out a group registration and have a group contact. I'd be willing
to handle all that, just thought I should ask here first to see if
everyone was ok with it. Thoughts?

--
Travis Watkins
http://www.realistanew.com
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz


[compiz] [dbus] add getMetadata to plugins

2006-12-14 Thread Travis Watkins

This patch adds support for getMetadata to plugins. It could probably
use better strings for core. I need this for my dbus-based
configuration GUI.

--
Travis Watkins
http://www.realistanew.com
diff --git a/plugins/dbus.c b/plugins/dbus.c
index b6b4e97..89a639c 100644
--- a/plugins/dbus.c
+++ b/plugins/dbus.c
@@ -806,6 +806,36 @@ dbusHandleGetMetadataMessage (DBusConnection *connection,
 int	nOption = 0;
 DBusMessage *reply = NULL;
 
+reply = dbus_message_new_method_return (message);
+
+//check to see if we've been called on a plugin
+if (!path[1])
+{
+if (!strcmp(path[0], core))
+{
+char *shortDesc = General Options;
+char *longDesc = Options for Compiz as a whole;
+dbus_message_append_args (reply,
+  DBUS_TYPE_STRING, shortDesc,
+  DBUS_TYPE_STRING, longDesc,
+  DBUS_TYPE_INVALID);
+}
+else
+{
+CompPlugin *p;
+p = findActivePlugin (path[0]);
+if (p)
+{
+dbus_message_append_args (reply,
+  DBUS_TYPE_STRING, p-vTable-shortDesc,
+  DBUS_TYPE_STRING, p-vTable-longDesc,
+  DBUS_TYPE_INVALID);
+}
+}
+}
+else
+{
+
 option = dbusGetOptionsFromPath (d, path, s, nOption);
 
 while (nOption--)
@@ -815,8 +845,6 @@ dbusHandleGetMetadataMessage (DBusConnection *connection,
 	CompOptionType restrictionType = option-type;
 	char	   *type;
 
-	reply = dbus_message_new_method_return (message);
-
 	type = optionTypeToString (option-type);
 
 	dbus_message_append_args (reply,
@@ -878,6 +906,7 @@ dbusHandleGetMetadataMessage (DBusConnection *connection,
 
 	option++;
 }
+}
 
 if (!reply)
 	reply = dbus_message_new_error (message,
@@ -919,7 +948,7 @@ dbusHandleMessage (DBusConnection *connection,
 if (!dbus_message_get_path_decomposed (message, path))
 	return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
 
-if (!path[0] || !path[1] || !path[2] || !path[3] || !path[4])
+if (!path[0] || !path[1] || !path[2] || !path[3])
 	return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
 
 if (strcmp (path[0], org)	   ||
@@ -951,8 +980,7 @@ dbusHandleMessage (DBusConnection *connection,
 	status = dbusHandleGetOptionMessage (connection, message, d, path[3]);
 }
 else if (dbus_message_has_member (message,
-  COMPIZ_DBUS_GET_METADATA_MEMBER_NAME) 
-	 path[5])
+  COMPIZ_DBUS_GET_METADATA_MEMBER_NAME))
 {
 	status = dbusHandleGetMetadataMessage (connection, message, d,
 	   path[3]);
___
compiz mailing list
compiz@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/compiz