Author Topic: How can I programmatically resize a wxFrame?  (Read 316 times)

Offline Landslyde

  • Multiple posting newcomer
  • *
  • Posts: 46
How can I programmatically resize a wxFrame?
« on: August 07, 2018, 10:56:47 am »
i have a form set up that uses wxDEFAULT_DIALOG_STYLE. Given certain conditions, I want its width to grow from 780 to 1200. I've tried
Code: [Select]
wxFrame->SetSize(1200,900);and
Code: [Select]
wxFrameBase->SetClientSize(1200,900);but that doesn't work. I get an error:
Code: [Select]
1071|error: expected unqualified-id before -> token|
I know I'll get rocks thrown at me, but I can't figure this out.
« Last Edit: August 07, 2018, 11:09:15 am by Landslyde »
Linux Mint 19
Code::Blocks 17.12
GCC 7.3.0

Offline stahta01

  • Lives here!
  • ****
  • Posts: 6368
    • My Best Post
Re: How can I programmatically resize a wxFrame?
« Reply #1 on: August 07, 2018, 11:10:26 am »
You need to use the object name instead of the class name is my guess.

But, it is a off topic question for this site; that is best asked on https://forums.wxwidgets.org/

Tim S.

C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 32 bit.
On Debian Stretch, compiling CB Trunk against wxWidgets 3.0.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Landslyde

  • Multiple posting newcomer
  • *
  • Posts: 46
Re: How can I programmatically resize a wxFrame?
« Reply #2 on: August 07, 2018, 11:26:34 am »
Will do. Thanks.
Linux Mint 19
Code::Blocks 17.12
GCC 7.3.0