পৃষ্ঠাসমূহ

Search Your Article

CS

 

Welcome to GoogleDG – your one-stop destination for free learning resources, guides, and digital tools.

At GoogleDG, we believe that knowledge should be accessible to everyone. Our mission is to provide readers with valuable ebooks, tutorials, and tech-related content that makes learning easier, faster, and more enjoyable.

What We Offer:

  • 📘 Free & Helpful Ebooks – covering education, technology, self-development, and more.

  • 💻 Step-by-Step Tutorials – practical guides on digital tools, apps, and software.

  • 🌐 Tech Updates & Tips – simplified information to keep you informed in the fast-changing digital world.

  • 🎯 Learning Support – resources designed to support students, professionals, and lifelong learners.

    Latest world News 

     

Our Vision

To create a digital knowledge hub where anyone, from beginners to advanced learners, can find trustworthy resources and grow their skills.

Why Choose Us?

✔ Simple explanations of complex topics
✔ 100% free access to resources
✔ Regularly updated content
✔ A community that values knowledge sharing

We are continuously working to expand our content library and provide readers with the most useful and relevant digital learning materials.

📩 If you’d like to connect, share feedback, or suggest topics, feel free to reach us through the Contact page.

Pageviews

Thursday, March 30, 2017

PyGTK - Window Class

An object of the gtk.Window class provides a widget that users commonly think of as a Wwindow. This widget is a container hence, it can hold one child widget. It provides a displayable area decorated with title bar and resizing controls.
gtk.Window class has the following constructor −

gtk.Window(type)
Type paramter takes one of the following values −
gtk.WINDOW_TOPLEVEL (default) This window has no parent. The Toplevel windows are the main application window and dialogs.
gtk.WINDOW_POPUP This window has no frame or decorations. A popup window is used for menus and tooltips.
Some of the important methods of the gtk.Window class are listed below −
S.NO Methods and Description
1 set_title(string)
This sets the "title" property of the gtk.window to the value specified by the title. The title of a window will be displayed in its title bar.
2 get_title()
This returns the title of a window if set.
3 set_position()
This sets the position of window. The predefined position constants are −
  • gtk.WIN_POS_NONE
  • gtk.WIN_POS_CENTER
  • gtk.WIN_POS_MOUSE
  • gtk.WIN_POS_CENTER_ALWAYS
  • gtk.WIN_POS_CENTER_ON_PARENT
3 set_focus()
This sets the widget specified to be the focus widget for the window.
4 set_resizable()
This is true by default. set_resizable() helps the user to set the size of a window.
5 set_decorated()
This is true by default. If false, the title bar and the resizing controls of window will be disabled.
6 set_modal()
If true, window becomes modal and the interaction with other windows is prevented. This is used for the Dialog widgets.
7 set_default_size()
This sets the default size of the window to the specified width and height in pixels.
The gtk.Window widget emits the following signals −
activate-default This is emitted when the default child widget of window is activated usually by the user pressing the Return or Enter key.
activate-focus This is emitted when the child widget with the focus is activated usually by the user pressing the Space key.
move-focus This is emitted when the focus is changed within the window's child widgets when the user presses the Tab, the Shift+Tab or the Up, Down, Left or Right arrow keys.
set-focus This is emitted when the focus changes to widget in window.

No comments:

Post a Comment