Code::Blocks Forums

Developer forums (C::B DEVELOPMENT STRICTLY!) => Development => Topic started by: Biplab on May 23, 2007, 10:37:09 am

Title: wxWidgets-2.8.x and dialog size problems
Post by: Biplab on May 23, 2007, 10:37:09 am
Hi All,

Since C::B has been switched to wx 2.8.4, several dialog sizes have increased in size. E.g., Find in files progress dialog, Editor Settings dialog, etc. Editor settings dialog has increased in size so much that in 800x600 resolution, it's virtually impossible to click it's OK, Cancel buttons.

Another problem is that the dialogs are now shown in wrong places. Such as File properties dialog; if it's called from Project Manager, the dialog is placed at wrong position. Same is true for Editor Settings dialog, too. This problem may be solved by using Multi-monitor support of C::B. But for the first problem the solution is still unavailable.

Why is it behaving so??  :o

Regards,

Biplab
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: wxLearner on May 23, 2007, 12:38:07 pm
Looking at changes.txt after wxWidgets-2.8.0, it could have been introduced with wxWidgets-2.8.2:
Quote from: changes-2.8.2.txt (http://downloads.sourceforge.net/wxwindows/changes-2.8.2.txt?modtime=1173799547&big_mirror=1)
All (GUI):
...
- The old wxADJUST_MINSIZE behaviour is now the default behaviour for
  sizer items that are windows.  This means that GetAdjustedBestSize
  will now be called by default to determine the minimum size that a
  window in a sizer should have.  If you want to still use the initial
  size (and not the BestSize) then use the wxFIXED_MINSIZE flag.  When
  windows are added to a sizer their initial size is made the window's
  min size using SetSizeHints, and calls to wxSizer::SetItemMinSize
  are also forwarded to SetSizeHints for window items.
EDIT: Sorry, that were changes made in wx-2.5.2  :oops:

Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: Biplab on May 23, 2007, 01:13:18 pm
Thanks for your reply. But that change was introduced in wx 2.5.2. :)
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: killerbot on May 23, 2007, 01:45:45 pm
even with wx263 and 800*600 several dialogs don't show entirely on screen and ok button can't be reached. Have a linux box, where suse refuses do detect the graphics chip  and I am stuck with that crappy resolution
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: David Perfors on May 23, 2007, 01:54:12 pm
The fact is that the size is increased since wx2.8.x On my Laptop (1024x800) I could always see the full settings dialog. Now I have to move it to get it fully viewed. the strange thing is that the space isn't used (except for the button bar at the side).
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: Biplab on May 23, 2007, 01:55:28 pm
May be all the dialogs needs minor tweaks to respect Screen Resolution. On my Windows box this is not a problem, but in Linux box (in VMware) I'm facing this problem.

But why they have increased in size when wx 2.8.x is used?? This is bugging me a lot. I tried couple of weeks back to fix this. But got no headway. :(

Edit 1: I tried tweaking the XRC files. But no avail.

Another interesting note is, Editor Configuration dialog is resizable (At least it shows sizing cursors). But if you try to do so, it will refuse to resize.
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: David Perfors on May 23, 2007, 01:59:08 pm
Did someone filled a bug report for this?
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: Biplab on May 23, 2007, 02:05:57 pm
Not yet. But may be we need to file a bug report.
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: rickg22 on May 23, 2007, 10:32:53 pm
I agree, one of the dialogs in CB is awfully huge, but forgot which one. I may check tonight.
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: David Perfors on May 24, 2007, 03:16:56 pm
Thee is already a similar bug reported: http://developer.berlios.de/bugs/?func=detailbug&bug_id=11142&group_id=5358 (http://developer.berlios.de/bugs/?func=detailbug&bug_id=11142&group_id=5358)

Does this problem also exists on Linux?
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: Biplab on May 24, 2007, 04:41:50 pm
That bug report is different. But unfortunately I couldn't reproduce that bug in Windows. Though that bug exists in Linux.

The problem I reported in this thread can be seen in Linux, too.
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: David Perfors on May 24, 2007, 08:13:26 pm
Hmm. I thought it was the same kind of bug because of not properly sizing of windows...
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: Biplab on May 24, 2007, 08:31:14 pm
It's really annoying. It not only screws up the size, it screws up the window position, too. :evil:

I don't know what they've done with wx code. But as I said, positioning bug can be solved by using C::B's multi-monitor support. For the Ultra-wide, Jumbo-sized windows bug, I'm still looking for a solution.
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: Biplab on May 26, 2007, 12:38:50 pm
BTW, to inform all, Yiannis has just committed a fix in the repo which would fix Jumbo-sized Windows. :D

@Yiannis, I tried to perform the surgery on the XRC file. But my surgery failed (a specialist was needed ;)).

Regards,

Biplab
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: mandrav on May 26, 2007, 12:59:44 pm
@Yiannis, I tried to perform the surgery on the XRC file. But my surgery failed (a specialist was needed ;)).

I have only tested this in winXP+wx2.8.4. We still need to test under other platforms/wx-versions.
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: Biplab on May 26, 2007, 01:04:42 pm
Just curious, Does that fix solve the dialog being placed in wrong position?

I didn't test it yet. But when I loaded the XRC file into XRCEd, it threw me couple of missing parameters error.

Quote
18:41:44: Required parameter label of wxButton missing
18:41:44: Required parameter label of wxButton missing
18:41:44: Required parameter min of wxSlider missing
18:41:44: Required parameter label of wxButton missing
18:41:44: Required parameter label of wxButton missing

Regards,

Biplab
Title: Re: wxWidgets-2.8.x and dialog size problems
Post by: mandrav on May 26, 2007, 02:36:36 pm
Just curious, Does that fix solve the dialog being placed in wrong position?

Yes it does.

I didn't test it yet. But when I loaded the XRC file into XRCEd, it threw me couple of missing parameters error.

Quote
18:41:44: Required parameter label of wxButton missing
18:41:44: Required parameter label of wxButton missing
18:41:44: Required parameter min of wxSlider missing
18:41:44: Required parameter label of wxButton missing
18:41:44: Required parameter label of wxButton missing

I edited the xrc with wxSmith.