Commit Graph

4981 Commits

Author SHA1 Message Date
Vadim Zeitlin
19be42b760 Make art provider id of type "char *" instead of "wxChar *".
These strings don't need to be wide and, as elsewhere, prefer the
compatibility with 2.8 ANSI build to compatibility with Unicode build.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66503 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-31 17:38:51 +00:00
Vadim Zeitlin
7b8983996e Show wxART_BUTTON icons in art provider sample resource browser.
The button icons have a different size from all the other clients in wxGTK so
it may be interesting to see them in the sample, add wxART_BUTTON to the list
of art clients that can be chosen in it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66501 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-31 17:38:35 +00:00
Jaakko Salli
61fac071c3 Removed AdvImageFileProperty from the wxPropertyGrid sample. It was somewhat impractical and bug-prone.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66458 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-27 11:50:34 +00:00
Jaakko Salli
6ea6c5127c Test wxPropertyGrid::DoubleToString()
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66457 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-27 11:25:53 +00:00
Vadim Zeitlin
41271da4af Use stock ids for menu items in the config sample.
This not only removes some unnecessary code from the sample but also fixes a
problem due to the use of a 0 id under wxOSX (which is unsupported there).

Closes #12788.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66428 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-22 13:57:08 +00:00
Vadim Zeitlin
98f8e6666b Add the possibility to disable invisible wxDataViewCtrl items.
Add new wxDataViewModel::IsEnabled() and wxDataViewListStore::IsEnabledByRow()
methods and implement support for actually disabling the items in wxOSX/Cocoa
native implementation of wxDataViewCtrl and limited support for it in the
generic version.

We need to implement this in wxGTK using GtkCellRenderer "sensitive" propriety
later.

Closes #12686.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66403 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-12-19 15:02:56 +00:00
Vadim Zeitlin
6eefca4fb7 Allow wxAutomationObject::GetInstance() create new instance if needed.
When getting an instance of an OLE automation object, it is often useful to
connect to the existing instance if any or start a new one otherwise. Make
GetInstance() behave like this by default while still allowing to use the
wxAutomationInstance_UseExistingOnly flag to reestablish the old behaviour.

Also improve the error reporting in wxAutomationObject.

See #12489.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66262 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-26 13:30:37 +00:00
Vadim Zeitlin
ccec90930c Add wxVersionInfo and functions returning it for 3rd party libraries.
Add simple wxVersionInfo class holding the version information.

Also add GetLibraryVersionInfo() static method to wx{JPEG,PNG,TIFF}Handler,
wxStyledTextCtrl and wxXmlDocument classes and wxGetZlibVersionInfo() and
wxGetLibraryVersionInfo() global functions using it.

Closes #12690.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66259 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-25 00:53:44 +00:00
Jaakko Salli
780cccd730 Reworked wxSystemColourProperty::StringToValue() to use wxColour::Set() instead of doing string-to-colour conversion by itself. This adds support for HTML-colours, among other things (closes #12696).
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66217 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-20 11:58:54 +00:00
Vadim Zeitlin
6ab66823d8 Don't use some "recent" C++98 features not supported by VC6.
Don't return void values nor redeclare the same variable in for loops to fix
VC6 compilation.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66168 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-16 22:38:06 +00:00
Jouk Jansen
3e90629b6b Update OpenVMS makefile
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66161 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-15 08:52:56 +00:00
Vadim Zeitlin
553d672896 Make menu operations always work with "Test" menu in the sample.
Some tests in the "Menu" menu of the menu sample worked with the "Test" menu
while others used the last one ("Help" initially but possibly something else
if the test commands from "Menubar" menu were used).

Harmonize all menu commands to use the "Test" menu now.

See #12668.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66138 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-13 15:02:50 +00:00
Vadim Zeitlin
08e78a5412 Add a test for deleting a sub-menu to the menu sample.
Also fix some typos in the help message.

See #12668.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66081 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-10 00:36:50 +00:00
Vadim Zeitlin
9b341e6fa1 No changes, just simplify docview sample a bit.
Remove some unnecessary function arguments and m_frame member variable.

Closes #12374.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66079 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-10 00:36:39 +00:00
Vadim Zeitlin
125c2fccdc Reformat long lines in the new part of the xrc sample.
No changes, just break the too long lines.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66063 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-07 19:33:38 +00:00
Vadim Zeitlin
14f0c8b716 Use Connect() of Bind() in the new part of xrc sample.
Use Connect() for compatibility (notably with VC6 which doesn't support
Bind()). Also connect the event handlers on loading the dialog instead of
waiting until the relevant page is selected, this makes the code slightly
simpler as we don't need to remember whether we connected them or not any
longer.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66062 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-07 19:33:30 +00:00
Vadim Zeitlin
f7aaef4d53 Test both ChangeSelection() and SetSelection() in notebook sample.
Test wxBookCtrl::SetSelection() too to be able to check that it does generate
events as expected.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66061 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-07 19:33:22 +00:00
Vadim Zeitlin
0526c8cc07 Add support for id ranges to XRC.
Allow to declare ranges of consecutive IDs in XRC by using the "id[n]" syntax.
Show this functionality in the xrc sample and test it in the new unit test.

Also show and test the "object reference" XRC functionality.

Closes #11431.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66059 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-07 14:00:59 +00:00
Vadim Zeitlin
4ded4e1910 Remove test code accidentally committed as part of r66015.
Don't call wxMenuItem::Set{Background,Text}Colour() in the menu sample, this
was for testing only.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66018 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-05 12:53:44 +00:00
Vadim Zeitlin
e801524514 Use explicit menu item background if it's given under MSW.
An explicit item background colour specified in user code should override the
default theme background.

Closes #12652.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66015 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-04 10:57:19 +00:00
Vadim Zeitlin
9939bfd98b Remove unused mouse event handler from dataview sample.
The mouse event handler for the frame was never executed because the frame is
entirely covered by other windows in this sample. Not sure what was meant here
but this handler is useless so just remove it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66009 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-03 23:48:30 +00:00
Vadim Zeitlin
d632aa8157 Remove unnecessary tests for m_log from dataview sample.
The sample contained a lot of unnecessary checks for m_log, remove them to
make the code shorter and simpler to understand.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66008 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-03 23:48:23 +00:00
Jouk Jansen
0de66257d9 Update OpenVMS compile support
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65999 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-03 08:54:52 +00:00
Václav Slavík
d0154e3a5a Add optional columns autosizing to wxDataViewCtrl.
Only implemented in the generic and GTK+ versions at the moment, OS X
support will be added later.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65948 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-30 15:57:41 +00:00
Vadim Zeitlin
6969b18cc7 Fix wrong wxLogDebug() call in fswatcher sample.
Replace wxLogDebug() with wxLogTrace() as was probably intended. This fixes
the assert which happened when running the sample because of the wrong number
of parameters passed to wxLogDebug().

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65908 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-24 22:41:18 +00:00
Vadim Zeitlin
5fc3e6d448 Allow specifying the directory to watch on command line of fswatcher sample.
This makes it more convenient to run the sample repeatedly as the directory to
watch can be specified only once instead of having to choose it interactively
after the sample startup every time.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65907 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-24 22:41:13 +00:00
Vadim Zeitlin
e4545e0183 Allow to use space to toggle spinning of the cube in OpenGL sample.
Small enhancement to the cube OpenGL sample.

Closes #11545.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65904 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-24 22:40:58 +00:00
Vadim Zeitlin
22993989b4 Don't send wxEVT_COMMAND_TREE_ITEM_MENU event without valid item in wxMSW.
The generic wxTreeCtrl version only sends this event when the mouse is right
clicked on a valid item so do the same in wxMSW version too for consistency.

This is also consistent with wxEVT_COMMAND_TREE_ITEM_RIGHT_CLICK event and
avoids strange problems with unexpected wxEVT_COMMAND_TREE_ITEM_MENU events
generated on right double click.

Finally, replace the checks for item validity in the event handler in the
sample with asserts which should loudly complain if it happens to be invalid.

Closes #11226.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65903 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-24 22:40:52 +00:00
Vadim Zeitlin
164db92c14 Add support for specifying child process cwd and env to wxExecute().
Add an optional wxExecuteEnv parameter to wxExecute() which allows to specify
the initial working directory and custom environment for the child process.

Closes #12163.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65896 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-24 22:40:11 +00:00
Vadim Zeitlin
fab8784c71 Treat wxToolbook symmetrically with others in the notebook sample.
Use wxToolbook as the default notebook type if the other ones are not
available.

Closes #12610.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65895 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-24 22:40:01 +00:00
Vadim Zeitlin
7c4e16e698 Use wxChoicebook instead of wxNotebook in the xrc sample.
wxNotebook was unusable with so many pages under all platforms and completely
unusable under Mac. Replace it with wxChoicebook which allows to select any
page quickly instead of having to do it sequentially (or not being able to do
it at all under Mac).

Another possibility could be to use wxTreebook and organize the pages in
categories, similarly to how it is done in the widgets sample.

Closes #3699.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65891 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-24 14:34:12 +00:00
Vadim Zeitlin
85edc04591 Rearrange xrc sample controls in alphabetical order.
Several new pages were added in random positions, rearrange them to be in
alphabetical order.

Also remove wxToolBar from "The Rest" page as it is shown in one of the other
pages now.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65890 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-24 14:34:05 +00:00
Vadim Zeitlin
c5d7b7d20b Don't use non-existent icon in XRC sample.
appicon.xpm was removed so use another icon in the controls demo in the sample
instead, it doesn't matter which one we use anyhow.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65886 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-23 18:56:37 +00:00
Vadim Zeitlin
4689441b05 Add XRC handler for wxToolbook.
Closes #11615.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65885 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-23 18:56:28 +00:00
Vadim Zeitlin
53cdd2c11d Add XRC handler for wxCommandLinkButton.
Added a handler for wxCommandLinkButton class and a demo of it in the xrc sample.

Closes #12593.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65856 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-20 23:11:20 +00:00
Vadim Zeitlin
528f2a25ca Merge wxBitmapButton and wxButton panels in the xrc sample.
There are already way too many pages in the "Controls Example" in the sample,
combine wxBitmapButton and wxButton ones to save some space and make it more
usable.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65855 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-20 23:11:09 +00:00
Peter Cawley
140091e55c Improve support for ribbon panel sizers: panels with sizers should now automatically minimise at small sizes, and behave properly when popping up from a minimised state.
Patch by johnr in trac issue #12580.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65852 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-20 17:49:42 +00:00
Julian Smart
5ad9ae3a29 Fixed #12566 (assert on deletion) due to inconsistent commit
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65805 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-14 18:06:02 +00:00
Jaakko Salli
ed8b46bba3 When wxPGProperty is un-attached from wxPropertyGrid, keep its 'default' cell references invalid/NULL (fixes #12552)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65788 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-10 09:34:29 +00:00
Vadim Zeitlin
6e91bf4d5b Remove unnecessary check from IPC sample.
No real changes, just remove a check for pointer passed to wxDELETE() bot
being NULL as wxDELETE() already checks for this anyhow.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65781 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-07 20:43:20 +00:00
Julian Smart
bec80f4f4a Eliminated redundant wxRichTextAnchoredObject class; refactored XML I/O code
so that objects can stream themselves; added a wxXmlDocument-based method
of writing XML, though this turned out to be much slower than writing directly
so the direct approach is retained and is the default (can be changed with wxRICHTEXT_USE_XMLDOCUMENT_OUTPUT).
Loading and saving new attributes implemented. Added custom properties to objects.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65779 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-06 20:22:03 +00:00
Vadim Zeitlin
d275b15d14 Fix harmless unused variables warnings.
Don't initialize the variables we never use in richtext sample, this results
in g++ warnings.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65767 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-05 13:37:25 +00:00
Julian Smart
2477747881 wxRTC no longer derives from wxTextCtrlBase; added wxRichTextAttr deriving from wxTextAttr
with CSS-like attributes for future developments; removed image-specific attributes object


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65756 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-10-04 08:37:31 +00:00
Vadim Zeitlin
ce00f59b5b No changes whatsoever, just remove trailing whitespace.
There are no real changes in this commit but it removes all trailing white
space from our source files. This avoids problems when applying patches and
making diffs and it would be nice to prevent it from reappearing.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65680 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-30 11:44:45 +00:00
Vadim Zeitlin
cdaed652d7 Merge of SOC2010_RTC_IMAGES branch.
Added floating images and image property dialog to wxRichTextCtrl, by Mingquan
Yang as part of GSOC 2010. Also changed image block creation to use a memory
stream instead of creating a temporary file.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65676 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-30 10:27:07 +00:00
Vadim Zeitlin
b4607e897c Correct drawing of mnemonics in wxStaticBox label under wxMSW.
Only show the mnemonics if they need to be shown, i.e. use the same logic as
the standard controls use, to avoid showing mnemonics in wxStaticBox with
custom label colour even when other wxStaticBoxes don't show it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65580 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-21 11:44:47 +00:00
Vadim Zeitlin
2af006ebd3 Fix wxStaticBox label redrawing when "Alt" is pressed in wxMSW.
The default handling for Alt key press in the standard control is to redraw
the label to account for showing of the keyboard queues (i.e. if the mnemonics
were initially hidden, they are shown when Alt is pressed) but it doesn't
redraw it in the correct colour resulting in any custom label colour being
lost whenever Alt is pressed anywhere in the window containing the box.

Fix this by forcing the box refresh which will result in repainting it using
our code which does use the correct colour.

Also update the static page of the widgets sample to allow changing the
colours of all static controls on this page, including the wxStaticBox, and
not just the main wxStaticText.

Closes #12497.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65579 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-21 11:44:41 +00:00
Dimitri Schoolwerth
b5b208a179 Set svn properties on .cpp files.
Add missing svn:eol-style property to all .cpp files. Also set svn:keywords for .cpp files which don't have that property yet to Id, including src/osx/core/glgrab.cpp for consistency (it doesn't make use of the property).


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65561 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-17 11:17:55 +00:00
Vadim Zeitlin
75595b9750 Only use wxFORCE_LINK_MODULE() in mediaplayer sample in static build.
The linking optimization this macro protects against can't happen when using
DLL and so using it is at best useless and actually harmful (because it
doesn't contain the correct DLL export declarations) in the latter case.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65558 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-16 11:05:51 +00:00
Robert Roebling
d8090b5e2c Further work on wxDataViewListModel::Reset()
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65538 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-13 20:02:01 +00:00
Vadim Zeitlin
e7b12eece0 Improve printing out of pressed keys in the keyboard sample.
Add missing elements of wxKeyCode enum ("Windows" and "Command" keys) to the
GetVirtualKeyCodeName() function in the sample.

Also output "unknown" and not blank for WXK_NONE.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65524 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-11 10:18:57 +00:00
Vadim Zeitlin
b6885972ee Fixes to key codes in keyboard events generated by wxMSW.
Only set Unicode key code if the event corresponds to a character key and set
it to (newly added) WXK_NONE for the other ones to avoid nonsensical values in
it for e.g. "Home" key presses.

Also set non-Unicode key to WXK_NONE for the characters that can't be
represented in the current locale. This is consistent with wxGTK and avoids
conflicts between special key values and Unicode keys.

Clearly document the above behaviour.

Notice that implementing the correct behaviour in wxMSW involved untangling
previously interwoven WM_KEY{DOWN,UP} and WM_CHAR messages handlers. Clearly
separate them now as they get different input (key codes for the former,
characters for the latter) and especially don't try to convert from both kinds
of input using a single wxCharCodeMSWToWX() function. As this function doesn't
need to distinguish between keys and characters any more it can simply return
the converted value in all cases instead of returning 0 sometimes to indicate
a character value instead of a key. Simplify the code using this function
accordingly.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65522 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-11 10:18:47 +00:00
Vadim Zeitlin
f434800ca3 Add a possibility to show a progress dialog on dialog sample startup.
Add a command line option to the dialogs sample to allow testing of different
wxProgressDialog styles more easily. This also tests for showing them before
the main event loop is started (see r65499).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65502 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-10 17:25:35 +00:00
Vadim Zeitlin
ca9fc039c1 Fix cast of pointer to int in artprov sample.
This prevented the sample from building when using MinGW-64 and also probably
prevented it from working correctly on other 64-bit systems.

Closes #12453.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65495 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-09 22:20:07 +00:00
Vadim Zeitlin
b54ceb72ce Remember last values used in exec sample "Kill" menu item dialogs.
Remember the PID entered in the dialog and also remember the last used signal
number. This makes these dialogs slightly less painful to use when testing
even though ideally we'd have a single dialog for choosing both values instead
of two consecutive modal dialogs.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65492 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-09 21:49:25 +00:00
Vadim Zeitlin
9b10161eb6 Force linking of all wxMSW wxMediaCtrl backends in mediactrl sample.
Force the linker to include all the backends in the sample executable instead
of discarding them because they are not used directly to allow testing all of
them in the sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65485 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-09 20:33:51 +00:00
Vadim Zeitlin
6d9db33c47 No changes, just remove cruft from mediactrl sample.
Remove the test for wxUSE_GUI together with the comment questioning its
presence.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65484 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-09-09 20:33:47 +00:00
Robert Roebling
66ddc77b88 Add possibility to use sizers in ribbon panel, fixes #12404: wxRibbonPanel and wxSizer
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65436 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-29 09:42:55 +00:00
Vadim Zeitlin
232fdc630c Merge the new GUI tests from SOC2010_GUI_TEST branch.
Add a lot of tests for many wx GUI classes.

Add tests using the new wxUIActionSimulator class but disable them under OS X
as too many of them currently fail there.

Refactor the test suite to make organizing the existing tests and adding the
new ones easier.

Improve documentation using the information gathered while testing the
classes. Also update the documentation of the testing system itself.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65386 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-22 22:16:05 +00:00
Vadim Zeitlin
571d991bb3 Merge wxUIActionSimulator fixes from SOC2010_GUI_TEST branch.
Correct a lot of problems with the initial implementation, notably make the
API consistent across all platforms, e.g. all keyboard-related methods now
take just a wxKeyCode.

Add some useful higher-level helpers such as Text() and MouseDragDrop().

Improve documentation.

wxUIActionSimulator now works under MSW, GTK and OS X and is enabled by
default.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65385 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-22 22:15:42 +00:00
Vadim Zeitlin
c31d9c7f60 Use task dialog for wxProgressDialog implementation in wxMSW.
If available, the task dialog is now used for the wxProgressDialog under
Windows. This provides a much more native looking dialog which doesn't look
out of place under modern Windows versions, unlike the generic implementation.

The internals of the code had to be significantly changed as the task dialog
can only be shown modally so, to emulate wxProgressDialog modeless nature, a
separate thread is used for the progress dialog management.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65352 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-18 22:49:02 +00:00
Vadim Zeitlin
a1bdd4ab9b Add wxRichMessageDialog class.
This is a generalization of wxMessageDialog based on the native task dialog
under recent (Vista and later) Windows versions and implemented generically
for the other ports for now.

It provides the possibility to use additional controls in the message boxes
(checkbox useful for the "Don't ask me again" kind of dialogs and collapsible
detailed explanations field) and better look and feel under Windows.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65349 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-18 22:48:41 +00:00
Vadim Zeitlin
3571e1add4 Add new wxCommandLinkButton class.
A command link button wraps a native MSW control under recent Windows versions
and is implemented generically as a simple bitmap button elsewhere.

In the future, GTK implementation should allow using a different font for the
button label and its note.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65327 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-17 14:48:50 +00:00
Vadim Zeitlin
27607839f1 Use wxPanel as controls parent in wrapsizer sample.
Follow our own advice about never creating controls directly on the frame and
using an intermediate wxPanel in our own sample. This is better style and
makes it look better under Windows.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65239 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-10 21:48:22 +00:00
Vadim Zeitlin
d931703342 Inherit notebook background recursively under wxMSW.
With MSWSetTransparentBackground() hack only the panel which was the immediate
child of wxNotebook (i.e. its page) inherited the notebook background but not
its children. This resulted in jarring background discontinuities when nested
panels were used.

Fix this by inheriting notebook background in all child panels by testing for
the return value of the parents MSWHasInheritableBackground() method in
wxPanel::HasTransparentBackground() recursively.

Closes #12317.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65238 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-10 21:48:17 +00:00
Vadim Zeitlin
5ed0415e3e Don't use bitmap still selected in wxMemoryDC in image sample.
The bitmap must be deselected from wxMemoryDC before being used in any other
way but the sample didn't do this. Fix this by simply destroying the DC as
soon as we don't need it, this makes bitmap available for other use as well.

Closes #12310.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65232 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-10 18:57:47 +00:00
Vadim Zeitlin
80ce465c64 Add wxDataViewCtrl::{Set,Get}CurrentItem().
Current item is the same as the selected item in single selection mode but in
multiple selection mode there was no way to neither get this item nor change
it before so add the new functions to allow doing this now.

The new methods are implemented for the generic, GTK and OS X/Cocoa versions
but only stubs are provided for OS X/Carbon.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65228 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-10 12:53:03 +00:00
Jaakko Salli
6c78066f22 Moved wxPGProperty::SetFlag() to protected API since it does not have any side-effects that are usually desired in the user code. Added wxPGProperty::SetAutoUnspecified() since wxPG_PROP_AUTO_UNSPECIFIED can no longer be set (conveniently) with SetFlag().
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65218 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-08 12:22:08 +00:00
Vadim Zeitlin
4e848be7f6 Fix dataview sample compilation with wxUSE_DRAG_AND_DROP==0.
This allows to build it under wxX11. Unfortunately it still doesn't work at
all there.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65213 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-08-08 11:37:46 +00:00
Robert Roebling
e78778c8e2 Add ability to render checkbox in undeterminate state, fixes #12290: wxRendererGTK does not support wx.CONTROL_UNDETERMINED for checkboxes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65139 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-29 16:57:09 +00:00
Vadim Zeitlin
54f0a3242c No changes, just use traditional English name for Mozart's work.
In English, this work (K. 525) is always referred to with its indefinite
article included and its appearance without it is jarring.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65113 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-26 10:08:19 +00:00
Francesco Montorsi
4a31544cb5 no real change: just follow wx typical commenting style and separe // from the following characters with a space
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65095 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-25 09:52:13 +00:00
Jaakko Salli
6a0a70c979 Set 'Min' attribute for the sample wxFloatProperty
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65093 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-25 09:23:25 +00:00
Jaakko Salli
ec88eb712e Use default wxPropertyGrid validation failure behavior in the sample
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65092 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-25 09:19:52 +00:00
Vadim Zeitlin
e39877cdb7 Remove selection showing code from the grid sample.
This code is broken as it doesn't always show the selection correctly and
doesn't handle rows-or-columns selection mode at all. Until we can fix it
properly it's better to not have it at all so that at least people avoid
copying the wrong code into their own programs.

Closes #12195.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65075 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-24 11:56:11 +00:00
Vadim Zeitlin
9ea83ebc7c Add test for a custom cursor to the image sample.
Load a cursor from PNG file to check that it appears as expected.

See #11989.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65073 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-24 11:49:05 +00:00
Vadim Zeitlin
ab5259d977 No changes, just slightly improve docview sample code.
Call the base class version of OnClose() in the derived classes instead of
duplicating it.

Closes #11363.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65064 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-23 23:33:27 +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
2c83a950a4 Store the result of wxWindow::NewControlId() in wxWindowIDRef.
The result of calling NewControlId() must be assigned to wxWindowIDRef to be
accounted for correctly, otherwise the id was marked as free while a reference
to it still existed resulting in asserts in id management code when we
attempted to reuse it.

Closes #11604.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65059 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-23 23:32:56 +00:00
Vadim Zeitlin
a5bb451448 Allow passing multi-line strings to wxDC::DrawText(), even under MSW.
Native wxMSW wxDC::DrawText() implementation doesn't support multi-line
strings so use the generic wxDC::DrawLabel() code instead. Drawing multi-line
strings now works at least in wxGTK and wxMSW, to be tested for the other
platforms.

Closes #12239.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65058 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-23 23:32:52 +00:00
Vadim Zeitlin
e22fa4d7b2 Fix mismatches between format strings and arguments.
This corrects the asserts which are now triggered when the actual arguments
don't match the format string.

Closes #12265.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65054 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-23 23:32:30 +00:00
Vadim Zeitlin
9b481f66e5 Remove executable bits from plist files.
These files probably don't need to be executable.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65039 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-22 12:09:10 +00:00
Vadim Zeitlin
f203de0cc4 Replace 2.9.1 version with 2.9.2.
Also update the inc_release script to take src/wxWindows.xcodeproj into
account.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65038 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-22 12:09:04 +00:00
Vadim Zeitlin
b0f73b6701 Really set svn:eol-style property.
The last commit used incorrect property name, remove the erroneous property
and set the correct svn:eol-style one.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64996 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-17 14:55:45 +00:00
Vadim Zeitlin
63ced01b22 Generate key events in generic wxDataViewCtrl implementation.
Forward wxEVT_CHAR events from wxDataViewMainWindow to the parent window so
that they could be processed at wxDataViewCtrl level.

Call DisableKeyboardScrolling() to ensure that cursor movement keys are not
always eaten by the parent window but can be used for the navigation in the
control if they're not processed by user.

Add a test keyboard handler to the dataview sample to check that handling keys
in wxDataViewCtrl does work.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64957 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-14 11:12:03 +00:00
Vadim Zeitlin
e0ff229573 No changes, just use better names in wxDataViewCtrl sample.
ID_DELETE_MUSIC button deleted selected items so use ID_DELETE_SEL and
OnDeleteSelected() handler for it instead.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64956 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-14 11:11:58 +00:00
Vadim Zeitlin
526954c596 Globally use "wxWindows licence" consistently.
Use "wxWindows licence" and not "wxWidgets licence" (the latter doesn't
exist) and consistently spell "licence" using British spelling.

See #12165.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64940 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-13 13:29:13 +00:00
Vadim Zeitlin
6e3837d003 Replace remaining references to 2.9.0 with 2.9.1.
Also update the tech note listing the places that need to be changed when a
new version is released and the script which updates them automatically.

Finally update a couple of copyright years.

Closes #12185.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64913 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-12 22:49:59 +00:00
Jaakko Salli
525b29124a Added 'Delimiter' attribute for wxArrayStringProperty. Moved static ArrayStringToString() to wxArrayStringProperty.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64894 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-11 17:04:23 +00:00
Vadim Zeitlin
679ab0b315 Optionally set the window name in wxPersistentRegisterAndRestore().
In practice names are not often used so typically whenever you want to make a
window settings persistent you also need to set its name and the it's
convenient to let a single function do both tasks, so add an overload taking
the name string (this is a separate function instead of optional parameter to
avoid compilation errors if this is ever used with non-wxWindow-derived
objects which don't have SetName() method).

Also expand the documentation slightly and add @since tags.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64887 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-11 10:44:23 +00:00
Vadim Zeitlin
ac63bc407e Set the string to search for in wxSearchCtrl events.
It's more convenient to have the string to search for directly in the event
object than to retrieve it from wxSearchCtrl itself as it had to be done
before.

Closes #4665.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64886 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-11 10:44:18 +00:00
Jaakko Salli
2906967c4a wxArrayEditorDialog now uses wxEditableListBox. It has also been renamed to wxPGArrayEditorDialog.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64867 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-10 15:30:35 +00:00
Robert Roebling
a8fde0a8d0 Fix assert in dataview sample, fixes #12194: wxDataViewCtrl sample asserts in wxArgNormalizer
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64806 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-07-04 08:25:28 +00:00
Vadim Zeitlin
4c5ec23654 Remove duplicate sample.xpm inclusion from stc sample.
This sample already included sample.xpm even before the recent changes
replacing mondrian.xpm (which it also included) inclusion with sample.xpm so
now it included it twice.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64726 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-06-25 08:47:17 +00:00
Francesco Montorsi
81ec0e15af move console sample's interactive tests to two different CppUnit testsuites: InteractiveInputTestCase which requires user input and InteractiveOutputTestCase which outputs stuff to be checked from the user.
Leave in the console sample only a barebone console application (i.e. a real example).

Closes #11960

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64679 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-06-21 21:03:47 +00:00
Vadim Zeitlin
ae4ea4e862 Remove references to joytest.rc that was recently removed.
Another fix to samples compilation after recent changes removing unneeded
icons and resource files.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64666 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-06-21 12:19:10 +00:00
Vadim Zeitlin
85a0778e6a Suppress bogus g++ warnings about uninitialized variables.
The variables are always initialized but for some reason (at least the Apple
version of) g++ gives warnings for them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64665 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-06-21 12:19:04 +00:00
Vadim Zeitlin
412d690e49 Remove references to not existing any more griddemo.rc file.
The file was removed in a recent commit but the bakefile was not updated.

Do it now and rebake the makefiles.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64659 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-06-20 18:18:41 +00:00
Vadim Zeitlin
cc31b3c6a5 Correct the name of the XPM file containing the icon in xrc sample.
This fixes a compilation error introduced during de-mondrianization of the
samples.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64658 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-06-20 18:18:36 +00:00
Vadim Zeitlin
5276b0a53c Use wxDELETE() and wxDELETEA() when possible.
Use wxDELETE[A]() functions which automatically NULL out their arguments after
deleting them instead of doing it manually.

Closes #9685.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64656 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-06-20 18:18:23 +00:00