Problem with table packing....



Hi,
  I have written on program to show a window with a menu bar in. I am
hereby sending the function also. I main program I am calling this
function. But when I execute it. The height of the window is more... ( I

am using a monitor of resoulution 1200x1000). The winodw goes even
beyond my botton border of monitor. Bu when I remove the lie
"gtk_table_attach_defaults" is is working properly, but without the menu

in it. Can any body hep me in this......


The code goes like this........

GtkWidget *menubar;
  mainwindow_ = gtk_window_new(GTK_WINDOW_TOPLEVEL);

  gtk_window_set_title(GTK_WINDOW(mainwindow_), "GTK View ");

  gtk_signal_connect (GTK_OBJECT (mainwindow_), "delete_event",
GTK_SIGNAL_FUNC (gtk_main_quit), NULL);

 gtk_window_set_default_size(GTK_WINDOW(mainwindow_), 800,600);

  maintable_ = gtk_table_new (800, 600, TRUE);

  gtk_container_add (GTK_CONTAINER (mainwindow_), maintable_);


  get_main_menu (mainwindow_, &menubar);

  gtk_table_attach_defaults (GTK_TABLE(maintable_), menubar, 0, 599, 0,
20);
  gtk_widget_show (menubar);
  gtk_widget_show(maintable_);


NB: "maintable_" and "mainwindow_" are global variables.



Thanks in advace

Deekshit M

-------------------------------------------------------------------------------------------------------------------------
Information transmitted by this E-MAIL is proprietary to Wipro and/or its Customers and
is intended for use only by the individual or entity to which it is
addressed, and may contain information that is privileged, confidential or
exempt from disclosure under applicable law. If you are not the intended
recipient or it appears that this mail has been forwarded to you without
proper authority, you are notified that any use or dissemination of this
information in any manner is strictly prohibited. In such cases, please
notify us immediately at mailto:mailadmin wipro com and delete this mail
from your records.
----------------------------------------------------------------------------------------------------------------------


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]