Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 270755
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T00:03:11+00:00 2026-05-12T00:03:11+00:00

Is there a way in Gtk+ to stack one widget on top of another

  • 0

Is there a way in Gtk+ to stack one widget on top of another — not counting GtkFixed? GtkFixed doesn’t work well for two reasons: 1) I need Z order, and 2) I need one widget to stretch and fill provided space.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T00:03:11+00:00Added an answer on May 12, 2026 at 12:03 am

    I don’t think there is a proper container in standard GTK. I would subclass Gtk::Fixed… it is still the closest one you can get, and if you use gtkmm then subclassing shouldn’t be very difficult¹. Then you can control the dimensions of all widgets, stretching one selected child to fill space.

    To control Z-axis you will probably need to manipulate widget’s X windows–check GDK documentation on topic of GDK windows². I remember that in PyGTK each widget has gtk.Widget.window property, I guess that the same is for gtkmm. This assumes that all your child widgets have X windows, so f.e. you’ll need to wrap Gtk::Label inside Gtk::EventBox.

    ¹ http://www.gtkmm.org/docs/gtkmm-2.4/docs/tutorial/html/chapter-customwidgets.html

    ² http://www.gtkmm.org/docs/gtkmm-2.4/docs/reference/html/classGdk_1_1Window.html#6eef65b862344ad01b01e527f2c39741

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there a way to overlap (but not overwrite) two gtk.gdk.Pixbuf in a gtk.IconView
Is there any way in Notepad++ (or even with another tool) to change the
Is there a way, using the Gtk library in C, to clone a Gtk
Is there a way to force a gtk.Window object to ignore the Window Manager's
I am programming a card game in GTK. Is there a way to create
when I am programming with gtkmm, there is a widget Gtk::DrawingArea . I can
Is there a way to display a gtk.Spinner on a gtk.ToolButton instead of a
Is there some way to use the Menu.AttachToWidget(...) function of a gtk menu item
Is there any way to modify in webkit gtk to disable web security ?
Is there a way to store custom information with a widget? For instance, say

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.