Re: Panel Question
- From: joseph naoki kain <jkain scudc scu edu>
- To: gnome-list-request redhat com, gnome-list gnome org
- Subject: Re: Panel Question
- Date: Sat, 11 Apr 1998 13:45:35 -0700 (PDT)
>From gnome-list-request@redhat.com Sat Apr 11 12:19:22 PDT 1998
Received: from mail2.redhat.com (mail2.redhat.com [199.183.24.247]) by server1.scudc.scu.edu with SMTP (8.7.6/8.7.1) id MAA26291 for <jkain@scudc.scu.edu>; Sat, 11 Apr 1998 12:19:20 -0700 (PDT)
Received: (qmail 30052 invoked by uid 501); 11 Apr 1998 19:18:11 -0000
Resent-Date: 11 Apr 1998 19:18:11 -0000
Resent-Cc: recipient list not shown: ;
MBOX-Line: From gnome-list-request@gnome.org Sat Apr 11 15:18:10 1998
Message-ID: <19980411111600.30668@julia.5z.com>
Date: Sat, 11 Apr 1998 11:16:00 -0700
>From: George <jirka@5z.com>
To: gnome-list@gnome.org
Subject: Re: Panel Question
References: <199804111727.KAA21031@ws30.scudc.scu.edu>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Mailer: Mutt 0.85e
In-Reply-To: <199804111727.KAA21031@ws30.scudc.scu.edu>; from emacs on Sat, Apr 11, 1998 at 10:27:32AM -0700
Resent-Message-ID: <"9jPNf2.0.4L7.o7yBr"@mail2.redhat.com>
Resent-From: gnome-list@gnome.org
Resent-Reply-To: gnome-list@gnome.org
X-Mailing-List: <gnome-list@gnome.org> archive/latest/405
X-Loop: gnome-list@gnome.org
X-just-a-test: testing
Precedence: list
Resent-Sender: gnome-list-request@gnome.org
X-URL: http://www.gnome.org
Status: R
Quoting emacs (jkain@scudc.scu.edu):
> Hi, I have just started writing gnome apps and so far I have been
> able to figure out what I am doing. I have written a loadmeter
> that embeds itself into the panel. I figurered that it should change
> its orientation with the panel, and I have gotten that to work just fine.
> The problem I am having is that I can not determine the orientation of the
> panel when my applet starts. That is if the panel is vertical and the
> loadmeter is started my applet gets confused and starts out horizontal.
> How can I determine the orientation of the panel when I startup (ie
> without waiting for a change_orientation)? I tired using applet_get_panel
> but couldn't link to it (I guess it isn't in libpanel_applet. Should it be?)
> Thanks for any help.
you can only use the CORBA interface since you can't go directly into
the panel ...
in fact what you describe should be happening ... when the applet is
started it has no way of knowing the orientation so most applets start
out as horizontal ... but the panel should send an orientation change
which you will catch as an orientation change .... the panel doesn't
know the orientation for a while too so it can't provide it before ...
if it doesn't automatically send an orientation change on startup
something is wrong
George
--
------------------------------------------------------------------------------
George Lebl <jirka@5z.com> http://www.5z.com/jirka/
------------------------------------------------------------------------------
The following implements RSA in perl and is illegal to export from the US:
#!/bin/perl -sp0777i<X+d*lMLa^*lN%0]dsXx++lMlN/dsM0<j]dsj
$/=unpack('H*',$_);$_=`echo 16dio\U$k"SK$/SM$n\EsN0p[lN*1
lK[d2%Sa2/d0$^Ixp"|dc`;s/\W//g;$_=pack('H*',/((..)*)$/)
--
To unsubscribe: mail gnome-list-request@gnome.org with
"unsubscribe" as the Subject.
Ok, I dug around in the panel's main.c. Specifically the function
orientation_change(...). I added some g_prints just so I could
see what what going on. After the panel has been running my
applet gets a change_orient call like it should as this gets
dispached from the info->type == APPLET_EXTERN branch of
orientation_change. However when my applet is first started
it is of type APPLET_EXTERN_RESERVED and does not get reoriented.
Just to see would happen I tried changing orientation_change
to reorient applets of type APPLET_EXTERN_RESERVED. It crashed.
So my applet doesn't get an automatic change_orient call when
it starts up. So am I doing something wrong or the panel code
broken/unfinished?
I have one other question. When I do get a change_orientation call
(like when I change the orientation of the panel itself, then it works)
I resize my widget (a GtkDrawingArea) then I do gtk_queue_resize on my
plug to get it to resize. Everything resizes execept that the panel
gets kind of wide (its vertical) since the horizontal version of my
program is wide. The panel doesn't shrink now that my (vertical) applet
fits nicely. Should it? If so, how can I make it happen?
Joseph Kain
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]