Advertisement Jump to content
  • Advertisement
Sign in to follow this  
  • entries
    17
  • comments
    6
  • views
    9687

Looking better...

Sign in to follow this  
aftermath

259 views

So Sizers on wxWidgets are a perfect sollution for a dynamic UI. If you ever wanted to easely make a user interface that dynamically resized it's controls based on the window size then wxWidgets Sizers are for you.

UPDATE:





wxNotebook* notebook = new wxNotebook(this, -1);
notebook->AddPage(new wxPanel(notebook, -1), "Hello");

wxBoxSizer* topsizer = new wxBoxSizer(wxVERTICAL);
topsizer->Add(notebook, 1, wxEXPAND | wxALL, 5);

wxBoxSizer* buttonszr = new wxBoxSizer(wxHORIZONTAL);

buttonszr->Add(
new wxButton(this, -1, "Quit"), 0, 0);
buttonszr->Add(
new wxButton(this, -1, "Save"), 1, wxALIGN_RIGHT);
buttonszr->Add(
new wxButton(this, -1, "Save && Hide"), 1, wxALIGN_RIGHT);

topsizer->Add(buttonszr, 0, wxALL | wxEXPAND, 5);

SetSizer(topsizer);
topsizer->SetSizeHints(this);

Sign in to follow this  


0 Comments


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!