Commit Graph

84 Commits

Author SHA1 Message Date
Vadim Zeitlin
f6727a17a2 Add wxAuiManager::AlwaysUsesLiveResize()
This allows to check if it's worth specifying wxAUI_MGR_LIVE_RESIZE or
not and allows to get rid of the corresponding menu item in the sample
if it doesn't do anything anyhow.
2020-05-25 18:01:09 +02:00
Vadim Zeitlin
42a756d5fe Merge branches 'auidemo' and 'auibarmsw' of mimi89999/wxWidgets
Improve appearance of disabled AUI buttons

Use wxSYS_COLOUR_GRAYTEXT for the disabled buttons, it works better in
non-default themes.

Also show how a disabled button looks like in the aui sample.

See https://github.com/wxWidgets/wxWidgets/pull/1801

See https://github.com/wxWidgets/wxWidgets/pull/1803
2020-04-17 23:56:54 +02:00
mimi89999
87171a103a
Add disabled auibar item to auidemo 2020-04-15 14:33:09 +02:00
Paul Kulchenko
9d704706cb Respect AUI toolbar buttons sticky state in native MSW theme
Indicate that the items are sticky by always drawing them in a
hover-like state, as otherwise stickiness wasn't visible at all.

Closes #18496.
2019-09-14 20:20:05 +02:00
Igor Korot
f3e1f72f6d Test vetoing wxAuiNotebook page changing event in aui sample
Make it simpler to check whether vetoing the page changing event works
as it's supposed to.

See #4518.

Closes https://github.com/wxWidgets/wxWidgets/pull/1329
2019-05-26 16:47:23 +02:00
Blake-Eryx
f58ea62596 Remove (most) occurrences of wxT() macro from the samples
Also replace wxChar* with wxString.

Closes https://github.com/wxWidgets/wxWidgets/pull/945
2018-09-23 01:15:08 +02:00
Simon Rozman
770e0bcd16 Improve high DPI support in wxAui
Window initial/minimum/maximum sizes are now treated as logical pixels.

Furthermore, many margins and paddings are now converted using
wxWindow::FromDIP() to allow their growth in accord with screen DPI.
This places buttons on toolbars more apart on high DPI screens providing
space for easier touch operations.

Closes https://github.com/wxWidgets/wxWidgets/pull/933
2018-09-17 22:54:29 +02:00
Maarten Bent
a96171def4 Fix unused variable and parameter warnings in samples
These variables are only used in debug builds, causing warnings in release builds.
2017-11-25 17:52:08 +01:00
Vadim Zeitlin
ca96abd119 Remove more hard-coded wxSpinCtrl sizes from the aui sample
This should have been part of 672cf7d199
and is done for the same reason: hard-coding control width to 50
truncates it under wxGTK3 as it's much wider than this there.

Closes #17919.
2017-07-19 21:04:20 +02:00
Vadim Zeitlin
672cf7d199 Don't hardcode wxSpinCtrl size in the aui sample
This makes it too small when using GTK+ 3.22, resulting in GTK+ debug messages
about not having enough space for it -- and is, of course, wrong anyhow, as we
should always let controls determine their own best size.
2017-04-01 15:48:53 +02:00
Dimitri Schoolwerth
8f8d58d193 Use wx-prefixed macros throughout the repository.
Change {DECLARE,IMPLEMENT}_*CLASS and {DECLARE,BEGIN,END}_EVENT_TABLE
occurrences to use the wx-prefixed version of the macros.
2015-04-23 22:00:35 +04:00
Vadim Zeitlin
7b210ef041 Remove trivial difference with master before merge.
Somehow an empty line got removed in the AUI sample, restore it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77870 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-09-23 17:44:56 +00:00
Vadim Zeitlin
cc3acf904b add GetLabel/SetLabel implementation to wxWindowX11, the function just store the label string, but do nothing with it
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@77826 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-09-23 17:42:33 +00:00
Paul Cornett
5b4a70247c use "new" wx-prefixed macros in samples
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76222 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-30 07:07:55 +00:00
Paul Cornett
8b4ae731d3 use wxOVERRIDE
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76220 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-03-30 00:02:23 +00:00
Vadim Zeitlin
3f66f6a5b3 Remove all lines containing cvs/svn "$Id$" keyword.
This keyword is not expanded by Git which means it's not replaced with the
correct revision value in the releases made using git-based scripts and it's
confusing to have lines with unexpanded "$Id$" in the released files. As
expanding them with Git is not that simple (it could be done with git archive
and export-subst attribute) and there are not many benefits in having them in
the first place, just remove all these lines.

If nothing else, this will make an eventual transition to Git simpler.

Closes #14487.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@74602 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-07-26 16:02:46 +00:00
Vadim Zeitlin
11527fc9f0 Added support for page tooltips to wxAuiNotebook.
Allow setting tooltips for the tabs of the individual pages of wxAuiNotebook.

Closes #14216.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71204 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-04-16 12:12:26 +00:00
Vadim Zeitlin
0e27ef576e Don't duplicate wxImage::ConvertToDisabled() in wxAUI code.
Just reuse the existing function.

Also add an example of showing a disabled bitmap to the aui sample.

Closes #13303.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68210 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-07-09 23:36:44 +00:00
Dimitri Schoolwerth
4c51a665c6 Fixed various typos.
Applied patch by snowleopard2 fixing a bunch of typos such as misspellings and double words in the documentation. Combined the patch with some local queued typos waiting to be committed as well as adding new typo fixes inspired by the patch.

Function names with American spelling were not changed nor was third-party code touched. The only code changes involve some changes in strings that are translated ("Can not" -> "Cannot").

Closes #13063 (again).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67280 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-22 14:17:38 +00:00
Dimitri Schoolwerth
6636ef8ddf Use wxString's empty() when checking if the string is (non-)empty throughout wx.
Instead of constructs such as if "( s.length() )" and "if (s.length() > 0)" use "if ( !s.empty() )" instead. Similarly for "if (s.length() == 0)" or "if ( s.IsNull() )", use "if ( s.empty() )".
No code changes intended except for a few instances where a construct like "if ( s.length() && wxFileExists(s) )" was changed to not check the length of the string and let wxFileExists handle such cases.



git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66728 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-01-22 14:38:36 +00:00
Vadim Zeitlin
4254f67216 Add support for icons in wxAUI panes title bars.
Add wxAuiPaneInfo::Icon() method and shows its use in the sample.

Closes #12856.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66670 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-01-12 13:39:36 +00:00
Vadim Zeitlin
18f42b94df Remove calls to wxApp::SetTopWindow() from the samples and documentation.
It is definitely not necessary to call SetTopWindow() when there is only a
single top level window and it is arguable whether it's useful to do it even
when there are many of them so don't encourage its use in the documentation
and also remove all its occurrences from the samples.

Closes #12816.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66528 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-01-02 22:05:14 +00:00
Vadim Zeitlin
e5dcae09e6 Add support for auto-orientable toolbars to AUI.
Allow wxAUI to change the toolbar orientation depending on where is it docked.
It is also now possible to specify wxAUI_TB_VERTICAL or HORIZONTAL to force
the toolbar to be always oriented in the given sense and to prevent it from
being docked at the sides incompatible with it.

Closes #11712.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65061 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-23 23:33:10 +00:00
Vadim Zeitlin
0772a89875 Ensure that setting wxChoice height to its default value does set it.
Setting wxChoice height to its default value didn't change the height even if
the current height was different from the default. This resulted in problems
when a wxChoice was used inside a wxAuiToolBar because AUI temporarily reduces
the toolbar size to (1, 1) when docking it (thus ensuring that the height of
wxChoice is changed too) and generally didn't make sense.

Fix this by resetting the height to the default value if the value passed to
wxChoice::SetSize() is what it considers to be its default height.

Add a unit test for this bug and also add a wxChoice to AUI sample to allow
testing for wxChoice behaviour inside a wxAuiToolBar being [un]docked.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63708 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-18 15:07:39 +00:00
Vadim Zeitlin
917f228a1f Reset wxAuiNotebook selection to wxNOT_FOUND if it becomes empty.
The selection was 0 in a notebook without any pages which was wrong as it must
always be less than the page count.

Fix this in wxAuiNotebook itself and add an assert checking for this invariant
to the sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63642 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-06 13:30:01 +00:00
Vadim Zeitlin
f9199323a4 Make the code more clear in aui sample and avoid g++ 4 warning.
The code used bitwise XOR which was rather difficult to read and also resulted
in g++ 4 warnings about suggested parentheses.

Fix both issues by using bitwise AND and OR in two separate statements instead.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63633 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-03-05 23:55:23 +00:00
Julian Smart
64178c3602 Speed up adding pages during freezing
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@62815 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-12-08 14:07:43 +00:00
Benjamin Williams
b6d74808f6 fix misusage of wxFlexGridSizer that was causing an assert
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59860 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-03-26 08:34:27 +00:00
Benjamin Williams
d45d5bb2b2 updated aui sample to demonstrate/test wxITEM_RADIO support in toolbars
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59607 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-03-18 13:53:34 +00:00
Vadim Zeitlin
038d59e979 undo the change of r57522, it's not needed any more after r59136
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59137 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-02-25 21:01:53 +00:00
Julian Smart
68030cae69 Added wxAUI_MGR_LIVE_RESIZE flag for live sash sizing, the default on wxOSX
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57884 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2009-01-07 14:45:27 +00:00
Francesco Montorsi
88fff2a712 use accelerators for menu items and stock menu item labels for stock IDs
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57595 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-12-27 14:28:46 +00:00
Vadim Zeitlin
16a6495db3 call wxFlexGridSizer::AddGrowableRow() only when the sizer has enough rows for the indices to be valid
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57522 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-12-24 00:41:23 +00:00
Benjamin Williams
0766faa34e fix aui sample breakage; added some accessor methods to wxAuiToolBarItem
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55523 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-09-08 09:56:49 +00:00
Benjamin Williams
b5d196c1d4 updated aui sample
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55232 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-08-24 09:28:26 +00:00
Vadim Zeitlin
11986debff don't use the same tool ids for multiple tools, this is bad idea under Windows and breaks tool commands handling
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55120 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-08-18 13:40:18 +00:00
Vadim Zeitlin
1df90f2dbc add a combobox to one of the toolbars, just for testing
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@53488 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2008-05-08 13:28:21 +00:00
Julian Smart
5edb3cb52d Pass correct values to spin control
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44488 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-02-12 21:01:58 +00:00
Vadim Zeitlin
45e6e6f8ab call OnInit() from all samples to allow using standard command line options with all of them (patch 1623971)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44354 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-02-04 00:34:18 +00:00
Vadim Zeitlin
75d0223f8c corrected crash: need to set m_frame eariler (Wlodek Szafran, closes bug 1636225)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44241 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2007-01-18 14:03:16 +00:00
Robin Dunn
bc07ab17bf reSWIGged
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43574 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-10-11 04:44:52 +00:00
Benjamin Williams
95c82627c8 removed duplicate pane bug in sample application
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43566 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-21 09:04:33 +00:00
Benjamin Williams
348861327b fixed a center pane bug in sample
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43548 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-20 19:33:48 +00:00
Benjamin Williams
254a342953 renamed wxAUI_ART to wxAUI_DOCKART
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43465 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-17 11:28:17 +00:00
Benjamin Williams
45980d81f3 corrected sentence
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43402 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-13 21:00:52 +00:00
Benjamin Williams
b809d2a4bd added new features to welcome page
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43400 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-13 18:39:42 +00:00
Benjamin Williams
73212f3518 updated nomenclature in menu item
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43260 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-10 06:23:24 +00:00
Benjamin Williams
2b9aac3387 wxAuiNotebook bitmaps working now
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43198 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-08 15:19:38 +00:00
Benjamin Williams
50d5ad7d77 elipsis for oversized pane captions
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43164 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-07 15:40:23 +00:00
Benjamin Williams
9c1d6ef42e added image to root item of tree in aui sample
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@43152 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2006-11-07 09:31:42 +00:00