[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: Positioning....
- From: Felipe Paulo Guazzi Bergo <guazzibe dcc unicamp br>
- To: Olivier Deme <olivier deme airtel-atn com>
- cc: gtk-app-devel-list redhat com, recipient list not shown: ;
- Subject: Re: Positioning....
- Date: Thu, 26 Aug 1999 08:50:11 -0300 (EST)
On Thu, 26 Aug 1999, Olivier Deme wrote:
> > What is the simplest way to position my main window on the screen before
> > it
> > opens (or right after)?
>
> I am using:
>
> gtk_window_position(GTK_WINDOW(window),GTK_WIN_POS_CENTER)
>
> although this doesn't seem to garantee that the window will be placed at
> the center of the screen all the time.
> I think the window manager has the last word about that.
> Can someone confirm?
As far as I know this one puts the top left corner of the window in the
screen center instead of actually centering the whole window.
To actually center a window use gdk_screen_width() and gdk_screen_height()
to get screen size and use these values to calculate the correct top-left
corner position.
.........................................................................
Felipe Paulo Guazzi Bergo - guazzibe@dcc.unicamp.br
Undergraduate in Computer Engineering - Unicamp - Campinas - SP - Brazil
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]