Commit Graph

5404 Commits

Author SHA1 Message Date
Vadim Zeitlin
80791c37b5 Fix incorrect wxSizerFlags::Border() call in the scroll sample.
Using 20 instead of a wxDirection resulted in an assert, fix the syntax.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72937 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-11-10 00:52:31 +00:00
Vadim Zeitlin
7a78a93782 Add wxControl::GetSizeFromTextSize() to size the control to its text.
This function can be used to size a, say, wxTextCtrl to be exactly of the size
needed to enter the given amount of text in it.

This patch adds wxGTK implementation for wxTextCtrl, wxChoice and wxCombobox;
changes to the samples and the documentation.

Closes #14812.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72935 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-11-09 21:11:37 +00:00
Vadim Zeitlin
639dbb6dd6 Restore propagation of EVT_SEARCHCTRL_CANCEL_BTN events to the parent.
This was broken by r72581, add event.Skip() call to the handler for this event
added there.

Also add a handler for this event to the corresponding page of the widgets
sample to be able to test this.

Closes #14799.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72915 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-11-06 23:56:21 +00:00
Vadim Zeitlin
244e36e8e2 Slightly improve the date/time dialogs in the calendar sample.
Use CreateStdDialogButtonSizer() instead of constructing
wxStdDialogButtonSizer directly, not only this is shorter but it also makes
the "OK" button default correctly.

Also initialize the labels instead of leaving them initially empty.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72898 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-11-04 23:55:22 +00:00
Vadim Zeitlin
5c299305d4 No changes, just make it easier to tweak splitter sample.
The sample contains disabled code for using other type of windows than
MyCanvas for the splitter children but it didn't compile any more because the
variables were declared as wxScrolledWindow. Fix this by using just wxWindow
for them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72889 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-11-04 23:51:58 +00:00
Vadim Zeitlin
84605707d1 Added wxEVT_COMMAND_DIRCTRL_CHANGED for wxDirCtrl selection changes.
This makes it much simpler to react to the changes in the control, update the
sample to show it.

Closes #14792.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72842 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-11-01 17:15:08 +00:00
Vadim Zeitlin
efafcdca4a Add distclean target to samples/Makefile.
It is necessary because it is used by the distclean target of the top level
makefile.

Closes #14793.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72840 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-11-01 17:14:59 +00:00
Stefan Csomor
551c2dcf88 adding constants for newer OSX versions to make sure our conditional expressions are working with earlier SDKs
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72830 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-31 07:10:07 +00:00
Vadim Zeitlin
a715668100 Compare file paths using wxFileName, not wxString, in the sample.
Comparing paths using wxString is a bad idea as identical paths can be seen as
mismatching because of case-only differences.

Also, don't reset wxRadioBox selection from its selection handler, this
doesn't work under e.g. wxGTK and is a bad example.

Closes #14791.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72820 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-29 18:30:14 +00:00
Vadim Zeitlin
908d92cd83 Fix taskbar sample compilation under wxOSX/Cocoa.
Use wxTBI_XXX constants instead of wxTaskBarIcon::XXX ones which don't seem to
exist any longer.

See #11831.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72806 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-28 01:08:20 +00:00
Vadim Zeitlin
bdb4b8320d Break implicit dependency of "core" on "adv" via wxXmlResourceHandlerImplBase.
wxXmlResourceHandlerImplBase::GetAnimation() returned wxAnimation by value
which created references to wxAnimationCtrlNameStr and wxNullAnimation
symbols, defined in the "adv" library, in "core" when using Sun CC even though
they were not referenced directly.

Fix this by returning wxAnimation by pointer to keep it opaque for "core" code.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72782 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-27 00:46:58 +00:00
Vadim Zeitlin
614e38dbb2 Implement clipping in wxSVGFileDC.
Support setting the clipping region and add update the documentation and the
sample accordingly.

Closes #14462.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72762 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 23:40:41 +00:00
Vadim Zeitlin
0fccda2ced Respect wxFileName::DontFollowLink() in wxFileSystemWatcher.
Watch the link itself and not its target if DontFollowLink() had been called.

Closes #14543.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72751 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-24 18:21:31 +00:00
Vadim Zeitlin
74a59798c0 Add support for wxRibbonBar and related controls to XRC.
Add wxRibbonXmlHandler and an example of using it to the xrc sample.

Closes #12058.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72729 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-23 13:52:27 +00:00
Vadim Zeitlin
ccc040255c Fix wxGrid editors background painting.
There were two fundamental problems: first, we painted on a separately created
wxClientDC instead of using the wxPaintDC already available in wxGrid. Second,
we invalidated the control while painting, resulting in endless repainting, at
least under wxGTK.

Fix the first problem by passing wxDC to wxGridCellEditor::PaintBackground()
and the second one by not refreshing the control from there as it just seems
unnecessary.

Also pass the attribute by reference for consistency with
wxGridCellRenderer::Draw() and because this pointer can never be NULL.

Closes #2628.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72697 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-17 16:44:02 +00:00
Vadim Zeitlin
0b3ef556f5 Handle deletion of watched directories in wxFileSystemWatcher sample.
Don't assert when trying to stop watching a directory that doesn't exist any
more later.

See #14544.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72683 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-15 01:10:12 +00:00
Vadim Zeitlin
1dc17bcafb Make TAB behaviour in wxGrid more configurable.
Allow making TAB/Shift-TAB wrap to the next/previous row or going to the
next/previous control when the cursor is at the end/beginning of the current
row easily.

Also add wxEVT_GRID_TABBING event to allow customizing TAB behaviour even
further.

Update the sample to show the different possible standard behaviours and a
stupid example of a custom one (it would be probably more useful to implement
something a tad more realistic, e.g. tabbing to the next non-empty cell).

Closes #14711.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72672 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-13 22:55:18 +00:00
Vadim Zeitlin
90bad79f70 Set the standard sample icon for the exec sample.
Do this for consistency with all the other ones and also because it makes it
simpler to notice any unwanted icons for hidden windows created by this sample.

See #13251.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72666 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-13 22:52:59 +00:00
Vadim Zeitlin
d34d31f6d6 Implement incremental search in wxGenericListCtrl.
Mostly copy wxGenericTreeCtrl incremental search implementation to
wxGenericListCtrl (unfortunately there is no simple way to reuse this code
currently), including the recently added EnableBellOnNoMatch() method.

Update the sample to test it, the key event handling in it had to be modified
to allow it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72639 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-07 22:42:27 +00:00
Vadim Zeitlin
27bc919446 Add a possibility to beep on no match to wxGenericTreeCtrl.
For consistency with Windows, allow to optionally generate a beep when
incremental search in the tree control doesn't find anything.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72638 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-07 22:42:02 +00:00
Vadim Zeitlin
94f39d8181 Add a setting for the disabled text colour to wxRibbon art.
Allow specifying the text for the labels of the disabled items separately.

Closes #14721.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72619 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-10-04 23:23:41 +00:00
Vadim Zeitlin
0015757fec Don't call ClearAll() before LoadFile() in the stc sample.
There is no need to clear the control contents before loading a file into it
because LoadFile() is supposed to do this on its own (although currently it
doesn't, which will be fixed soon).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72593 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-30 22:26:58 +00:00
Vadim Zeitlin
1d178139b2 Make stc sample startup faster.
Don't show "About" dialog on startup, this has nothing to do with the purpose
of this sample and is just annoying.

Also, don't select the entire file after opening it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72592 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-30 22:26:36 +00:00
Vadim Zeitlin
f5413b878c Add support for background-color style to span element in wxHTML.
Add code for setting/restoring background mode and use it to implement support
for changing the text background colour.

Closes #14443.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72589 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-30 22:20:58 +00:00
Vadim Zeitlin
07d304d2aa Fix wxSearchCtrl recreation in the widgets sample.
The control wasn't readded to the sizer correctly after being recreated.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72576 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-28 23:50:05 +00:00
Vadim Zeitlin
ceddf94945 Remove unused SearchCtrlWidgetsPage::Reset() from widgets sample.
This method was simply unused and unneeded.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72575 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-28 23:49:42 +00:00
Vadim Zeitlin
209dc298e2 Don't send events for disabled ribbon bar buttons.
Hover and activation events were sent even for the disabled buttons which was
unexpected and inconsistent with wxRibbonToolBar, so don't do it.

Closes #14709.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72574 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-28 23:49:20 +00:00
Vadim Zeitlin
45df4bb6c2 Add "inherit" to <font> XRC tag.
This allows to construct a font based on the parent window font instead of
either fully specifying all font parameters or basing it on a standard font.

Closes #14632.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72572 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-28 23:48:34 +00:00
Robin Dunn
d0c8c55aca Reserve the whole style byte for styles. See #14688
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72555 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-25 23:53:40 +00:00
Robin Dunn
48d63da328 Scintilla's Point class no longer matches the structure of wxPoint, so we need to copy points to a wxPoint array instead of just typcasting Scintilla's array. Fixes #14687
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72554 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-25 23:53:14 +00:00
Vadim Zeitlin
73eb7ca93f Make wxWrapSizer demo in the layout sample more dynamic.
Allow adding checkboxes to and removing them from the wrap sizer to
demonstrate how it adjusts to its contents dynamically.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72536 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-22 16:16:30 +00:00
Vadim Zeitlin
42d7394119 Add help button support to wxRibbonBar.
Optionally show standard "Help" question mark button in the ribbon top right
corner and generate the appropriate event for it.

Closes #14576.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72495 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-15 23:19:59 +00:00
Vadim Zeitlin
66815259f5 Fix text origin and bounding box computations in wxSVGFileDC.
Text origin was calculated incorrectly for the rotated text and the bounding
box was wrong even in non-rotated case.

Fix this by using correct definition of the text anchor according to the SVG
specification and add a test to the svg sample demonstrating this.

Closes #14489.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72494 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-15 23:19:35 +00:00
Vadim Zeitlin
c3f641cb5e Add wxBITMAP_PNG() macro similar to wxBITMAP() but for PNG images.
Just as wxBITMAP() provides a portable way of loading bitmaps from either
Windows BMP resources or embedded XPM data depending on the platform,
wxBITMAP_PNG() hides the difference between loading bitmaps from PNG resources
under Windows and embedded PNG data elsewhere.

Also add wxBITMAP_PNG_FROM_DATA() macro which always loads PNG data from
memory: it's needed anyhow as part of wxBITMAP_PNG() implementation and some
people may prefer to always use it under all platforms.

Finally modify the image sample to demonstrate loading PNG images from both
resources and memory. This involved creation of a new Windows .rc file for it
and copying its data files to Resources bundle directory under OS X.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72477 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-13 17:15:25 +00:00
Steve Lamerton
0bfd90b3e7 Add generic wxFileSystem support to wxWebView using wxWebViewFSHandler.
Closes #14623.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72461 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-11 09:26:58 +00:00
Vadim Zeitlin
4a2c28bf68 Add a test of wxFilePickerCtrl::GetValue() to the widgets sample.
Make the current value of the control visible in its page.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72453 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-09 13:35:34 +00:00
Vadim Zeitlin
77e3a24a01 Add an informational message to the file picker page of widgets sample.
No real changes, just indicate that clicking the "Set initial directory"
button was indeed taken into account.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72452 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-09 13:35:12 +00:00
Vadim Zeitlin
948f48e725 Enable GL_CULL_FACE in OpenGL samples.
Without it, the hidden faces are shown resulting in wrong display of both the
cube and the penguin, at least with Mesa (but it also seems to be the correct
thing to do according to OpenGL documentation).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72433 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-09-08 15:46:27 +00:00
Vadim Zeitlin
9bd25c8670 Generate wxEVT_COMMAND_TEXT_ENTER events for generic wxSpinCtrl.
Pass wxTE_PROCESS_ENTER to wxSpinCtrlTextGeneric if it's specified for
wxSpinCtrl itself and also forward wxEVT_COMMAND_TEXT_ENTER events from it to
wxSpinCtrl itself.

This fixes lack of these events for wxSpinCtrlDouble under MSW and also lack
of them for any kind of wxSpinCtrl in the ports using generic version (notably
wxOSX).

Closes #14604.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72415 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-08-30 20:25:01 +00:00
Vadim Zeitlin
9e565667d0 Add wxSpinCtrl::SetBase() to allow entering hexadecimal numbers.
Add a generic SetBase() API even though right now only bases 10 and 16 are
supported as we might support other ones (e.g. 8?) in the future. Implement it
for MSW, GTK and generic versions.

Add controls allowing to test this feature to the widgets sample.

Add "base" property support to the XRC handler for wxSpinCtrl, document it and
test it in the xrc sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72414 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-08-30 20:24:38 +00:00
Vadim Zeitlin
cc699de848 Added wxSimplebook class: a wxBookCtrl without controller.
This new control allows the program to show one of the several pages without
allowing the user to change them (or even see that there are several of them)
himself.

This class is fully inline, so it doesn't add anything to the library and
hence doesn't need neither wxUSE_SIMPLEBOOK nor the corresponding configure
option.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72407 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-08-30 20:21:54 +00:00
Vadim Zeitlin
9ed3454e3d Remove unnecessary TranslateBookFlag() from the notebook sample.
It probably was needed before, when the flags had different values for
different controls, but is simply unused now.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72405 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-08-30 20:21:06 +00:00
Steve Lamerton
66ac040060 Add support for searching and highlighting a wxWebView.
Currently supports WebView on GTK and IE. Closes #14045.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72390 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-08-28 17:13:13 +00:00
Vadim Zeitlin
70f86dedfd Add page highlighting to wxRibbonBar.
Allow visually highlighting a page to make it more noticeable to the user.

Closes #14527.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72347 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-08-15 23:34:36 +00:00
Vadim Zeitlin
ea805d32e4 Remove unnecessary statement from the grid sample.
No real changes.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72291 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-08-03 15:36:21 +00:00
Vadim Zeitlin
7c8bfa876a Add an option to use wxTextCtrl as input window in keyboard sample.
Keyboard handling is subtly different in wxGTK for native controls and generic
wxWindows so add a way to test both of them in the sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72266 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-31 11:09:00 +00:00
Vadim Zeitlin
7c70331e28 Add expand/collapse button to wxRibbonBar.
This allows the user to toggle the ribbon bar visibility.

Closes #14530.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72261 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-30 17:53:36 +00:00
Vadim Zeitlin
c4f49d69cf Make keyboard sample output less confusing.
Warn if key presses occur when the input window doesn't have focus as the
usual key events are not generated then which could be understood as a bug in
the sample instead of the correct result.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72253 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-29 22:08:21 +00:00
Vadim Zeitlin
1043456035 Generate clipboard events for wxComboBox in wxGTK too.
These events were only generated for wxTextCtrl but should be sent for
non-readonly wxComboBox too, so refactor the code to allow its reuse from
wxComboBox.

Also add EVT_TEXT_PASTE handlers for both controls to the widgets sample for
testing.

Closes #14520.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72252 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-29 22:08:15 +00:00
Vadim Zeitlin
afbf46a317 Implement wxNotificationMessage using libnotify in wxGTK.
Use libnotify -- if detected by configure -- to provide native notifications
in wxGTK. Our API maps to libnotify one in rather straightforward way, we
might consider extending it to cover more of libnotify functionality
(categories, user-defined icons and, especially, actions) later.

Also update the dialogs sample to show another kind of notification and the
documentation to clarify the behaviour of various methods.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72218 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-27 15:36:54 +00:00
Vadim Zeitlin
2f7baaeccf Don't eagerly set wxKeyEvent position fields.
This results in a noticeable delay when using wxGTK via a remote X11
connection for every key event as a round trip to server is needed to get the
mouse pointer position every time a key is pressed or released.

Only provide the position on demand. And explain that it's actually not very
useful as it's simply the same as the current mouse position.

Closes #14361.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72207 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-24 20:45:52 +00:00
Vadim Zeitlin
1f7c17f405 Set up scrollbars correctly for wxWebView in wxGTK.
This allows Scroll{Lines,Pages}() methods inherited from wxWindow to work with
it.

Add a test of using them to the sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72203 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-24 20:45:25 +00:00
Vadim Zeitlin
0eb47013cf Allow passing the URL to open to webview sample on command line.
This makes it simpler to test the sample with other pages and especially local
HTML files.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72201 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-24 20:45:14 +00:00
Vadim Zeitlin
14a0b47dff Fix assert in webview sample when viewing pages without a title.
Trying to append a menu item with empty label resulted in an assert (at least
under wxGTK but probably elsewhere too), and in any case wasn't very useful,
so use "(untitled)" instead in this case.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72174 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-23 15:03:09 +00:00
Vadim Zeitlin
62490e9ea7 Use text/uri-list instead of x-moz-url in wxGTK wxURLDataObject.
The standard exchange format for URLs is text/uri-list and not the deprecated
and Firefox-specific x-moz-url, support for which was moreover implemented
incorrectly anyhow.

Also add an example of copying URLs to the dnd sample.

See https://developer.mozilla.org/En/DragDrop/Recommended_Drag_Types for more
information.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72159 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-20 11:55:00 +00:00
Vadim Zeitlin
5c14ec2640 Add possibility to hide and show again wxRibbonBar pages.
Added wxRibbonBar::ShowPage(), HidePage() and IsPageShown() methods and show
them in the sample.

Also add GetPageNumber() helper.

Closes #14471.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72070 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-13 11:46:43 +00:00
Vadim Zeitlin
ce2532fbc6 Properly use RemoveTree() in fswatcher sample.
We need to use RemoveTree() to remove watches for the paths added with
AddTree().

See #14480.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72067 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-13 11:22:10 +00:00
Vadim Zeitlin
e3e7f6e573 Allow saving images under a different name in the image sample.
Also allow saving in XPM format.

See #13905.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72030 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-11 11:42:47 +00:00
Vadim Zeitlin
7dd65e5abe Forbid setting hints for multi-line text controls.
This doesn't work anyhow, so make it explicit by asserting if an attempt to do
it is made. And document this.

Also add a test of SetHint() to the text sample to verify it still works.

Closes #14456.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72010 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-10 23:52:10 +00:00
Vadim Zeitlin
14b682f7c3 Increase version to 2.9.5.
Rebake all the project/make files.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72007 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-10 23:51:44 +00:00
Vadim Zeitlin
2de58153db Set string in wxEVT_COMMAND_COMBOBOX_SELECTED event in wxOSX/Cocoa.
Pass the selected string and not only its index in the event generated when
combobox selection changes in wxOSX/Cocoa.

Closes #14383.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71941 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-02 15:03:00 +00:00
Vadim Zeitlin
fcbf733155 Fix command line parsing in media player sample.
It was broken since the addition of the call to wxApp::OnInit() to
wxMediaPlayerApp::OnInit() -- as the base class parses the command line
itself, we need to use OnInitCmdLine() and OnCmdLineParsed() instead of doing
it manually if we call it.

Also don't load the play list saved in wxConfig if any command line parameters
were given as otherwise the saved files would be used first (this seems to
have been always broken...).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71926 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-02 00:16:12 +00:00
Vadim Zeitlin
3253852a7e VC6 compilation fix for the grid sample.
Use Connect() instead of Bind() which is not available for VC6.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71909 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-06-30 23:41:30 +00:00
Vadim Zeitlin
c21b99e0e2 Add wxRibbonBar::DeletePage() and ClearPages() methods.
Also add a trivial GetPageCount() helper.

Closes #14437.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71888 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-06-30 16:33:18 +00:00
Vadim Zeitlin
ff1aede620 Create wxStaticBoxSizer elements as children of wxStaticBox in XRC.
As we now recommend creating the controls shown inside wxStaticBox as its
children, and not siblings, follow our own recommendation by doing just this
in XRC handler of wxStaticBoxSizer.

Also add a test of using a tooltip with a wxStaticBoxSizer element to the XRC
demo showing that tooltips do work now for them, unlike before.

Closes #14431.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71886 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-06-30 16:33:10 +00:00
Vadim Zeitlin
7e3ea54f47 Add missing c_str() and similar calls to samples in STL build.
Don't rely on implicit conversion of wxString to char*/wxChar*, it doesn't
exist in STL build. Add explicit c_str(), wc_str() or t_str() calls.

Closes #14420.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71820 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-06-20 17:54:42 +00:00
Vadim Zeitlin
a15f0e42bc Fix ribbon sample compilation after r71642.
Add a missing header with declaration of wxMessageBox() for PCH-less
compilation.

Closes #14376.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71646 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-06-05 12:12:43 +00:00
Vadim Zeitlin
0a7ee6e0f4 Implement support for wxRIBBON_PANEL_EXT_BUTTON wxRibbonPanel style.
Show the "extension button" in the ribbon panel if this style is specified.

Also generate a specific event if this button is clicked.

Closes #14283.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71642 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-06-03 19:17:09 +00:00
Vadim Zeitlin
779e28da63 Add wxGrid::Render() for drawing the grid to any wxDC.
In particular, this allows to print the grid contents easily.

Closes #14294.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71577 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-27 13:00:19 +00:00
Vadim Zeitlin
816e7781b0 Fix menu sample compilation under wxOSX.
Include copy.xpm under all platforms as all of them support (even though
without necessarily implementing it) wxMenuItem::SetBitmap() now.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71512 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-20 20:29:15 +00:00
Julian Smart
32423dd824 Added pixel size capability to wxTextAttr and wxRichTextCtrl.
Fixed composite object positioning in centred and right-aligned
paragraphs.
Added field example to sample, and enabled pixel font size selection.
Added custom text and dimension scaling.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71505 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-20 12:25:22 +00:00
Vadim Zeitlin
3ecb4c01f2 Fix wrong format specifiers in the samples.
Use "%ld" instead of "%d" to format long values, using "%d" results in an
assert failure under LP64 systems as int and long have different sizes there.

Closes #14311.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71469 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-17 16:10:19 +00:00
Vadim Zeitlin
f919ae3477 Make variable containing port number an ushort in the sockets sample.
A port number is an unsigned short, not long, so don't make it long just
because wxCmdLineParser doesn't provide a convenient way to get the value of
an unsigned short option (it would be nice if it did...).

This fixes the problem with using "%d" format specifier with a long variable
as this resulted in an assert under LP64 systems.

See #14311.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71443 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-16 15:10:05 +00:00
Vadim Zeitlin
a0b13884b4 Don't use printf() with non-literal string as format.
Replace calls to printf() with puts() in the typetest sample.

See #14311.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71441 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-16 13:24:49 +00:00
Vadim Zeitlin
8e8d910979 Update the field widths on demand in wxStatusBarGeneric.
This ensures that the value returned from GetFieldRect() is always up to date,
even when this method is called from the user-defined wxEVT_SIZE handler, i.e.
before our own OnSize() could run.

Also remove the now unneeded hack with calling the base class OnSize() from
the statbar sample.

Closes #14268.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71365 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-05 11:22:09 +00:00
Vadim Zeitlin
f8ab0cdb3e Don't return NULL widget from wxFileCtrl page of widgets sample.
This makes all the common operations such as setting tooltip, colours &c on
this page simply crash.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71363 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-04 22:20:59 +00:00
Stefan Csomor
6e22db9e3e fixes #14178
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71342 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-05-02 18:44:23 +00:00
Vadim Zeitlin
c04be1a29f Added wxDataViewEvent::SetDragFlags() and GetDropEffect() methods.
Allow specifying the drag operation flags and retrieving the drop effect when
it's over for wxDataViewCtrl drag-and-drop.

Currently this is only implemented in the generic version.

Closes #12583.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71324 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-04-29 23:22:25 +00:00
Vadim Zeitlin
b90aca4cba Enable wxComboBox::SetString() test in the widgets sample.
It was disabled because it wasn't implemented for wxGTK at some time in the
past -- but it is implemented now, so there is no reason to not allow testing
it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71315 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-04-29 23:21:57 +00:00
Vadim Zeitlin
c8648b64a6 Fix harmless warnings about hiding base class virtual in dialogs sample.
GetTitle() added in r71213 resulted in virtual function warnings from g++, fix
them by renaming it to GetBoxTitle().

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71302 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-04-28 22:24:50 +00:00
Vadim Zeitlin
d60a9c00e4 Add possibility to change the test message box title in dialog sample.
All the other message box elements were configurable, so why not this one.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71213 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-04-17 13:57:18 +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
Paul Cornett
55a0fa4e54 non-pch build fix, closes #14140
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71013 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-26 15:44:31 +00:00
Vadim Zeitlin
c0795ce8ea Added wxTimePickerCtrl::GetTime() and SetTime().
These methods, taking broken down time representation, avoid the problems
arising due to DST complications when using wxDateTime to represent the time
as special care needs to be taken in this case to avoid using the date part
corresponding to a DST change date at which time is discontinuous.

Document the problem with the old functions and use the new ones in the
sample.

See #14137.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71004 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-25 23:17:01 +00:00
Vadim Zeitlin
dfb4176ac5 Add a test for wxComboBox::SetString() to the widgets sample.
This allows to easily test this function interactively, notably check what
happens when the currently selected string is changed under different ports.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70879 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-11 23:41:27 +00:00
Vadim Zeitlin
c1a9bcfbc5 Correct the test for wxHAS_IMAGES_IN_RESOURCES in listctrl sample.
wxHAS_XXX symbols need to be checked with #ifdef, not #if.

See #1614 (as this change was part of the patch submitted there, even if the
ticket itself is unrelated).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70850 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-09 10:12:43 +00:00
Vadim Zeitlin
1862529285 Exclude wxMSW-only code from wxUniversal build under Windows.
wxListCtrl::EndEditLabel() isn't available in wxUniv, it's wxMSW-only.

This fixes the sample compilation in wxUniv/MSW build.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70849 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-09 10:12:40 +00:00
Vadim Zeitlin
c0430d964d Added wxSplitterWindow::SetSashInvisible() and IsSashInvisible().
Also fix handling of wxSP_NOSASH.

Closes #14074.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70840 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-08 13:23:39 +00:00
Paul Cornett
d9a1b21859 avoid using wxDC::Blit() and wxDC::GetPixel() on window that is being painted, results are unpredictable on wxGTK
see #14067

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70823 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-06 04:26:33 +00:00
Vadim Zeitlin
bb5a951418 Use __WINDOWS__ for OS checks and __WXMSW__ for GUI checks (round 2).
This is continuation of r70796 and serves the same purpose.

Closes #14065, #14066.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70808 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-04 20:31:42 +00:00
Vadim Zeitlin
1580a10d87 Always provide wxMenuItem bitmap-related methods in wxMSW.
Define these methods even when wxUSE_OWNER_DRAWN is turned off for some
reason. This allows to avoid ugly tests for !defined(__WXMSW__) ||
wxUSE_OWNER_DRAWN in the code that just wants to set a bitmap for a menu item.

Closes #12664.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70801 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-04 00:29:55 +00:00
Vadim Zeitlin
e709239889 Use wxHAS_IMAGES_IN_RESOURCES instead of explicit platform checks.
Add a special symbol which is defined only if the icons and other images (e.g.
cursor) are in the separate resource files and don't need to be embedded as
XPMs in the main program.

This makes the checks more clear and more customizable as it's enough to
change wxHAS_IMAGES_IN_RESOURCES definition instead of changing many platform
checks.

Closes #14050.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70789 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-04 00:28:58 +00:00
Julian Smart
b4e415df52 Use a non-native toolbar on Mac so small buttons aren't stretched horribly.
The style combo control also appears now that the toolbar is non-native.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70771 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-03-02 08:55:25 +00:00
Vadim Zeitlin
b02dd12239 Use /bin/echo for creation of Mac OS X PkgInfo files.
The built-in of /bin/sh doesn't handle "-n" option that we use (at least not
under OS X 10.6), so we were getting "-n APPL????" in the generated files.
Fix this by using /bin/echo which does support this option.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70744 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-02-28 22:48:39 +00:00
Vadim Zeitlin
7193abfbc8 Use wxPageSetupDialogData instead of old wxPageSetupData everywhere.
No real changes, just don't use the old and kept for compatibility only
wxPageSetupData name.

Closes #13992.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70636 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-02-20 21:55:55 +00:00
Vadim Zeitlin
8b6af8eedd Don't use deprecated wxDataViewCtrl::StartEditor() in the sample.
Also document this deprecation in the change log and explain how to update the
existing code.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70575 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-02-12 22:18:59 +00:00
Vadim Zeitlin
1442168125 Implement wxBG_STYLE_TRANSPARENT support for wxGTK.
Use composited windows if supported by GTK+ for wxWindows with this background
style.

Also add wxWindow::IsTransparentBackgroundSupported() and show how to use it
in the sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70569 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-02-11 16:26:52 +00:00
Vadim Zeitlin
49a63afbad Avoid CRT deprecation warnings for MSVC build using makefiles too.
Define _CRT_SECURE_NO_DEPRECATE, _CRT_NON_CONFORMING_SWPRINTFS and
_SCL_SECURE_NO_WARNINGS when using makefiles to build the library too for
consistency with the project files.

These defines are only needed for VC8 and later but should do no harm for the
previous versions.

See #11009.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70532 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-02-07 21:38:31 +00:00
Vadim Zeitlin
ba7512e14d Rebake all project files to reflect MSVC deprecation warnings defines.
Rebake all the projects after the changes of r70182, even if they're only
really needed for the library itself, the other project files should
correspond to the bakefiles contents too.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70531 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-02-07 21:38:09 +00:00
Julian Smart
cc2aecdef5 Added further API for intercepting deletion and content insertion
Added simple implementation of locked objects to sample


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70465 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-25 15:10:09 +00:00
Vadim Zeitlin
c7a49742ec Add support for stricken-through fonts.
Support stricken-through fonts in wxMSW and wxGTK (including special support
in wxStaticText and wxTextCtrl).

Closes #9907.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70446 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-23 11:28:28 +00:00
Dimitri Schoolwerth
6e9d06080d deleted CodeWarrior project files
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70430 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-21 00:53:21 +00:00
Dimitri Schoolwerth
fdfa35b4d7 Fixed mismatch in amount of format specifiers in Japanese translation for i18n sample.
The translation was missing a %s, copied the translation from the same string at samples/internat/ja/internat.po.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70429 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-21 00:01:00 +00:00
Dimitri Schoolwerth
2d143b6689 Removed ellipsis from "About..." occurrences.
MS and Apple guidelines mention ellipses should generally be used when a command needs additional information from the user before the operation can execute. This is not the case for showing an about dialog so the ellipses have been removed.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70412 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-20 16:51:09 +00:00
Dimitri Schoolwerth
ecc8721a0a Changed .po files to use UTF-8 charset.
Changing the localisation files to be in UTF-8 allows them to be committed by the pre-commit hook script.

Also regenerated relevant .mo files.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70411 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-20 16:33:41 +00:00
Vadim Zeitlin
11c278c43c Respect image mask in the docview sample.
Draw images with transparency, if any.

See #13881.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70406 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-19 22:17:17 +00:00
Dimitri Schoolwerth
ebfe373ee7 replaced _T() usage with wxT()
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70393 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-18 23:10:59 +00:00
Václav Slavík
ee1377e1fa Add wxDataViewCtrl::GetCurrentColumn().
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70375 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-17 14:05:07 +00:00
Dimitri Schoolwerth
877af9bdd5 Deleted makefile.mgl.
The makefile referred to a file in src/mgl/, wxMGL has been removed since r70353 so this makefile can be deleted.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70372 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-17 06:12:17 +00:00
Vadim Zeitlin
f2012fa639 Remove __WXMGL__ tests from the samples too.
__WXMGL__ is not used any longer, remove it from the samples too.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70359 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-15 18:50:35 +00:00
Vadim Zeitlin
0e1f8ea4a3 Remove wxMGL port.
The company behind MGL toolkit (SciTech) doesn't exist since several years and
this port is not used by anybody, so remove it to ease maintenance burden.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70353 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-15 14:46:41 +00:00
Vadim Zeitlin
a73d72ae4a Remove more Palm OS left overs.
Remove the build files and the mentions of Palm OS in the widgets sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70351 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-15 13:43:19 +00:00
Steve Lamerton
cb9a0fbe65 Add missing aui dependencies to the notebook sample.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70321 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-12 10:26:51 +00:00
Vadim Zeitlin
d1bf0be0bc Enhance wxRibbonToolBar functionality to wxRibbonButtonBar level.
Allow inserting and deleting tools and not only appending them.

Add possibility to enable/disable and toggle tools.

Send wxUpdateUIEvent for the tools.

Add various properties accessors.

Closes #13835.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70297 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-08 14:52:56 +00:00
Vadim Zeitlin
22f772f8e3 Compilation fixes to joystick sample after r70279.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70287 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-07 16:35:02 +00:00
Vadim Zeitlin
3b2f80c205 Set Z-position correctly for wxEVT_JOY_ZMOVE events.
Z-move events don't have (x, y) position, but they do have Z-position which
needs to be set.

Also don't use (x, y) position for these events in the sample.

See #748.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70279 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-01-07 15:09:29 +00:00
Vadim Zeitlin
f01e56249a Allow using wxEVT_UPDATE_UI with wxRibbonButtonBar.
Generate wxUpdateUIEvent for the ribbon buttons to allow updating their state
using wxEVT_UPDATE_UI. Also update the same to show this.

Closes #12003.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70180 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-29 22:05:34 +00:00
Vadim Zeitlin
d159e96495 Improve layout in the samples to avoid problems under Mac.
Changes the samples to look better under Mac and avoid the worst problems such
as overlapping buttons or truncated controls.

Closes #11651.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70152 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-28 13:51:21 +00:00
Vadim Zeitlin
51ec29ea5d Always link with expat in monolithic build.
Fix linking errors when using wxXML in sttaic monolithic build: in this case
we must link with expat but it was listed too early, before wxWidgets
libraries using it, in the bakefile-generated makefiles.

Now add it to the end of the linker command line too by including -lexpat in
EXTRALIBS_FOR_BASE which are appended to the linker arguments.

Notice that now -lexpat is linked twice because it is still added by
<wx-lib>xml</wx-lib> in bakefiles, even in monolithic build, but I don't know
how to avoid it and it is harmless anyhow.

Closes #12573.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70116 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-25 13:28:01 +00:00
Vadim Zeitlin
864181f4f6 Implement wxNotebook::CalcSizeFromPage() for wxGTK.
The implementation is far from perfect as it relies on hard-coded margins but
is better than nothing as it allows wxNotebook best size determination and
SetPageSize() method to work correctly.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70112 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-24 18:19:26 +00:00
Vadim Zeitlin
59a2c19914 Added wxTimePickerCtrl page to the widgets sample.
Even if this page is pretty trivial, add it for consistency with
wxDatePickerCtrl.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70069 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:27:06 +00:00
Vadim Zeitlin
54450d0907 Reorganized the date picker page of the widgets sample.
Make it possible to set the picker styles and set its range and not only the
current value.

Also log the events generated by it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70068 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:27:02 +00:00
Vadim Zeitlin
4d0c23087a Fix horizontal alignment in icon view in generic wxListCtrl.
Ensure that all the items in the same column have the same width, so that
their labels are centred.

Closes #9227.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70066 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-20 21:21:38 +00:00
Vadim Zeitlin
08670ea85a Update version to 2.9.4 in version.bkl too and rebake everything.
Change the version for Unix shared libraries too.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70044 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-18 14:35:50 +00:00
Vadim Zeitlin
75cb911c7c Added wxFilePickerCtrl::SetInitialDirectory().
This method allows to configure the initial directory to be shown when
browsing for files in an initially empty wxFileDirPickerCtrl.

It is also available for wxDirPickerCtrl but is less useful there.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70043 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-18 12:34:47 +00:00
Vadim Zeitlin
c05b000c71 Incremented the version number to 2.9.4 everywhere.
The misc/scripts/inc_release script was used to update the versions.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70021 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-16 22:12:49 +00:00
Vadim Zeitlin
4fe4a7c50f Add wxEXEC_HIDE_CONSOLE flag allowing to unconditionally do it under MSW.
Also renamed wxEXEC_NOHIDE to wxEXEC_SHOW_CONSOLE for symmetry (keeping the
old name for compatibility, of course).

Extend exec sample to allow easily testing the different flags and adding more
of them later.

See #13676.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69964 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-08 20:22:55 +00:00
Vadim Zeitlin
1863484b08 Use '1'..'9' to simulate digits instead of WXK_NUMPADn.
Using WXK_NUMPADn with wxUIActionSimulator doesn't work under Unix, the
resulting GDK events have wrong keyval for some reason.

It would, of course, be nice to fix this but in the meanwhile use ASCII codes
to simulate the digits to at least allow doing this at all.

Also extend uiaction sample to allow testing text simulation.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69960 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-08 15:55:40 +00:00
Vadim Zeitlin
4c2b10acad Rebake after webview-related changes in common.bkl.
Forgot to rebake all files (and not just library ones) after changes of
r69589.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69912 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-02 12:04:51 +00:00
Vadim Zeitlin
edf5822ace Implement EVT_CHAR_HOOK for wxOSX/Cocoa.
Send wxEVT_CHAR_HOOK event from wxOSX/Cocoa code.

Also test for wxEVT_CHAR_HOOK in the keyboard sample and show the effect of
not skipping it.

Closes #12431.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69889 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-12-02 00:50:12 +00:00
Vadim Zeitlin
1d8d3cc5a1 Add support for custom numeric formats to wxGrid.
Allow %e and %g formats (as well as their upper-letter equivalents) in
addition to the default %f format for number display in wxGrid.

Closes #13583.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69856 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-28 13:23:33 +00:00
Vadim Zeitlin
09c0ebcf96 Don't hardcode the number of toolbar tools in the toolbar sample.
Use GetToolsCount() instead of the hardcoded 10 (which can be wrong if any
tools were added or removed).

See #13673.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69855 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-28 12:47:26 +00:00
Vadim Zeitlin
c66c8042ad Corrected handling of wxTB_HORZ_TEXT in the toolbar sample.
The value of flag could be lost when toolbar was recreated without using text
at all.

Closes #13572.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69854 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-28 12:47:23 +00:00
Vadim Zeitlin
c0c9009c8d Add support for digits and +/- sign to wxUIActionSimulator::Text().
Support the characters needed for number entry in wxUIActionSimulator::Text()
too.

Closes #13671.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69762 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-15 15:56:55 +00:00
Vadim Zeitlin
b6963858fb Added wxIMAGE_OPTION_ORIGINAL_{WIDTH,HEIGHT} wxImage options.
These options allow to retrieve the original image size if the image was
scaled during load.

Closes #13662.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69759 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-14 13:35:48 +00:00
Steve Lamerton
c49d2434e3 Set focus on the browser window after loading a url. Also fix a warning.
Closes #13660

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69748 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-13 12:57:28 +00:00
Steve Lamerton
a178852467 Replace the sample animation timer with an idle loops and the animation with a busy cursor.
Fixes #13518, #13658

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69744 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-12 20:49:40 +00:00
Jouk Jansen
e2847646e5 Add compile support for widgets sample on OpenVMS
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69731 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-10 14:41:14 +00:00
Steve Lamerton
f9a786f870 Correctly escape the error log messages in the wxWebView sample.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69701 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-08 13:23:45 +00:00
Vadim Zeitlin
c052f780a4 Use wxWindowUpdateLocker to speed up updates of the static widgets sample page.
See #13619.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69681 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-05 11:24:00 +00:00
Vadim Zeitlin
3a6b6a9889 Fix adding a control to two different sizers in the widgets sample.
A checkbox on the static page was added to two sizers at once, resulting in
heap corruption later. Fix this by adding it to the right sizer only.

Closes #13619.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69680 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-11-05 11:23:57 +00:00
Vadim Zeitlin
853f4764c0 Make the initial sash position work in splitter sample.
The initial splitter size must be set correctly when using gravity with
wxSplitterWindow as otherwise the sash would jump on first resize -- which was
exactly what happened in the splitter sample.

Add a SetSize() call to the sample with the comment explaining why is it
needed and also actually make it stick as the cached last size was not updated
before the splitter was split before.

Closes #9821.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69599 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-30 19:48:44 +00:00
Paul Cornett
34949efe0d revert (presumably unintentional) change from r59562, which caused auto-scroll sample selection to be broken for last 2.5 years
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69516 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-23 18:03:20 +00:00
Julian Smart
75936ec600 Applied patch #13534: wxRichTextCtrl: Make it easier to use TextEffects flags
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69512 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-22 13:19:40 +00:00
Václav Slavík
dc73d7f5d4 Cleanup of wxDataViewCtrl cell activation code.
Fix confusion of what cell activation is and inconsistence with native
handling in GTK+. Document the distinction between activating (~
editing) a cell and activating (double-clicking) the whole item.

Deprecate wxDataViewCustomRenderer::LeftClick() and Activate() methods,
replace them with single ActivateCell() that is called for both kinds of
activation.

Fix implementations so that ActivateCell() is not called on
double-click, when it shouldn't, and vice versa: don't send
wxEVT_COMMAND_DATAVIEW_ITEM_ACTIVATED for cell activation.

Partially reverts r67099 -- restores old 2.9 signatures of compatibility
LeftClick() and Activate() methods.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69473 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-19 16:20:17 +00:00
Vadim Zeitlin
e520c3f75c Added wxRichToolTip class.
It can be used to show more customizable tooltips than the native wxToolTip
but at the price of using generic implementation in some cases (actually
almost always now, with the exceptions of text control tooltips under MSW).

Extra features include:
 - The balloon-like tooltip form.
 - Possibility to show an icon.
 - Title display in a different form.

More customization could be added later. It should be also possible to fully
implement this class natively under MSW.

Update the dialogs sample to show the rich tooltips in action.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69463 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-18 21:57:02 +00:00
Vadim Zeitlin
06b3e19fcb Make it possible to close "shaped" sample from the menu.
The sample didn't define any handler for wxID_EXIT menu item, do add it.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69386 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-12 00:35:04 +00:00
Vadim Zeitlin
bbcf2821a1 Move SetBackgroundBitmap() from wxPanel to new wxCustomBackgroundWindow.
wxCustomBackgroundWindow is a new class allowing to set a custom bitmap for
the background of any window. The relevant code was mostly moved from wxPanel
to which it was added only recently (before 2.9.2) making it unnecessary to
preserve compatibility.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69378 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-11 17:07:43 +00:00
Vadim Zeitlin
fa378d369f Allow creating wxGraphicsFont without using wxFont.
This is mostly important to allow using wxImage-based wxGraphicsContext
without requiring X server connection under Unix: as wxFont can't be used
without X server, we needed another way to create wxGraphicsFont in this case.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69360 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-09 22:07:29 +00:00
Vadim Zeitlin
0a470e5ea5 Allow creating wxGraphicsBitmap and wxGraphicsContext from wxImage.
Provide a way to use wxGraphicsContext to draw on wxImage.

This is implemented internally by drawing on wxGraphicsBitmap which can be now
also created from wxImage.

Add a test of the new functionality to the image sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69358 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-09 22:07:22 +00:00
Steve Lamerton
7cd038613b Work around the fact that wxWebViewIE doesn't send page changing and page changed events during a refresh, yet IsBusy returns true.
Closes #13518

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69324 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-07 21:25:59 +00:00
Steve Lamerton
24fb46ea48 Delete the timer on close in the wxWebView sample. Fixes another memory leak.
See #13500

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69313 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-05 08:05:42 +00:00
Steve Lamerton
873ff54b1f Derive wxAuiNotebook from wxBookCtrlBase. Document wxAuiNotebookEvent which now derives from wxBookCtrlEvent. Update the notebook sample to add wxAuiNotebook as an option.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69280 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-10-02 10:29:00 +00:00
Vadim Zeitlin
569c7d8ccb Add wxTimePickerCtrl class.
Implement wxTimePickerCtrl natively for MSW and add a generic implementation
(very loosely based on the original class by Paul Breen) for the other
platforms.

Also update the calendar sample to show the new control.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69224 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-29 13:43:15 +00:00
Steve Lamerton
7892e035c9 Delete the menu on close in the wxWebView sample. Fixes most of the memory leaks.
See #13500

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69214 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-28 19:44:35 +00:00
Vadim Zeitlin
d7b3992a5f Replace erroneous comma with a semicolon in keyboard sample.
Fix typo in the sample, comma was used instead of a semicolon. The code still
worked correctly but make it look correctly too now.

Closes #13453.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69179 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-21 15:08:06 +00:00
Vadim Zeitlin
da2e758f83 Implement sorting in wxTreeListCtrl.
Allow the user to sort the control contents by clicking on the columns with
wxCOL_SORTABLE flag and also provide SetSortColumn() method to sort the
control programmatically.

Also add wxTreeListItemComparator class and SetItemComparator() method to
allow customizing the way the items are compared.

Update the sample to show how to define a custom comparator.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69176 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-21 15:07:53 +00:00
Steve Lamerton
4794f127cd Cause a compile time error in the wxWebView sample if no backend exists.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69083 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-14 12:39:30 +00:00
Jouk Jansen
821c2a3750 add compile support for thread sample on OpenVMS
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69071 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-12 10:57:44 +00:00
Steve Lamerton
92b4653a62 Rebake trunk after wxWebView merge and add missing project files for the wxWebView library.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69056 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-11 10:12:19 +00:00
Steve Lamerton
b2b31b87fb Merge the new wxWebView classes from the SOC2011_WEBVIEW branch.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69049 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-10 18:09:12 +00:00
Steve Lamerton
1d156af324 Merge in from trunk r68684 - r69046
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@69047 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-09-10 15:09:22 +00:00
Vadim Zeitlin
2669319136 Better support for flat lists in wxTreeListCtrl.
Override wxDataViewModel::IsListModel() to return true if wxTreeListCtrl
doesn't have any depth. This results in better display when using the generic
implementation of wxDataViewCtrl as no space is reserved for the (unnecessary)
expanders in this case.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68961 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-30 13:40:44 +00:00
Vadim Zeitlin
75bc8b3454 Added wxFLP_SMALL and wxDIRP_SMALL styles for wx{File,Dir}PickerCtrl.
These styles allow to use a smaller browse button as the standard one takes
too much space, often leaving too little of it for the more important text
control part.

Notice that both styles are, in fact, equal to wxPB_SMALL but only file and
directory pickers currently use it as it doesn't make sense for the colour and
font pickers.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68921 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-27 14:11:25 +00:00
Vadim Zeitlin
ea7ff9ad2a Auto complete file names in the text controls of wx{File,Dir}PickerCtrl.
There doesn't seem to be any reason not to do this in the controls which we
know are meant for entering file or directory names into them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68920 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-27 14:11:20 +00:00
Vadim Zeitlin
9a995b1a42 Make the file and dir picket controls expand in widgets sample.
The controls were too small to see long paths in them comfortably while there
was plenty of space in the page, use wxEXPAND flag for them.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68919 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-27 14:11:17 +00:00
Vadim Zeitlin
03dede4dc1 Add wxTextEntry::AutoCompleteDirectories().
As we already had MSW-specific AutoCompleteFileNames(), we can just as well
also add the also useful AutoCompleteDirectories() to be used with the text
controls used for path entry.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68918 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-27 14:11:13 +00:00
Vadim Zeitlin
d50fc4dc6d No changes, just fix a typo in wxBannerWindow documentation.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68917 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-27 14:11:09 +00:00
Vadim Zeitlin
524cb04066 Add new wxTreeListCtrl class.
This is a facade for wxDataViewCtrl allowing to easily work with multi-column
trees, possibly with an optional checkbox in the first column. Its API is very
similar to wxTreeListCtrl and it provides a simple migration path from the
latter.

Add the class itself, documentation for it and minimal unit tests.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68916 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-27 14:11:03 +00:00
Vadim Zeitlin
97f851007c Fixes to OpenGL samples to avoid asserts/crashes.
Don't call wxGLCanvas::SetCurrent() when the window is not shown.

Closes #13424.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68909 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-27 12:13:13 +00:00
Stefan Csomor
d3f81b8533 adding raw_control for osx
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68875 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-24 11:19:43 +00:00
Dimitri Schoolwerth
4ca8531f61 Added wxBITMAP_TYPE_TIFF and wxBITMAP_TYPE_TIFF_RESOURCE.
Having wxBITMAP_TYPE_TIFF and wxBITMAP_TYPE_TIFF_RESOURCE is more consistent with already using the complete short name of an image format elsewhere (e.g. wxBITMAP_TYPE_JPEG, not wxBTMAP_TYPE_JPG, and wxTIFFHandler as opposed to wxTIFHandler). Renamed all existing occurrences and kept the old enum values for backwards compatibility.

Also renamed occurrences of wxBITMAP_TYPE_RESOURCE to the already existing wxBITMAP_TYPE_BMP_RESOURCE.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68859 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-23 04:55:46 +00:00
Vadim Zeitlin
ae2047c32a Add XRC handler for wxBannerWindow and a test for it to the xrc sample.
Also document the new XRC format elements.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68840 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 12:18:56 +00:00
Vadim Zeitlin
ea11bf3abc Add new wxBannerWindow class.
A simple banner showing either a bitmap or some text on gradient background.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68838 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 12:18:43 +00:00
Julian Smart
abcb9c6e58 Fix duplicate variable for VC++ 6
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68835 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 11:27:44 +00:00
Steve Lamerton
33baee46ee Add new sample project files.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68832 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 09:21:16 +00:00
Steve Lamerton
98d689e403 Rebake
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68831 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-22 09:16:48 +00:00
Vadim Zeitlin
abfdefede3 Add wxWithImages helper mix-in with {Set,Get,Assign}ImageList() methods.
Avoid defining SetImageList() in several different places in wx API as not
only this resulted in (trivial) code duplication but this method also had
different semantics before: it didn't take ownership of the pointer passed to
it in wxTreeCtrl, wxListCtrl and wxBookCtrl and derived classes but did take
its ownership in wxDataViewTreeCtrl and wxRichTextFormattingDialog.

Harmonize this for all the classes now: SetImageList() never takes ownership
while AssignImageList() (which is now available in all classes having
SetImageList()) always does.

Also add convenience wxWithImages::GetImage() helper to avoid (more) code
duplication in wxDataViewTreeCtrl code.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68809 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-21 14:08:43 +00:00
Steve Lamerton
467d261e9d Rename web library to webview.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68789 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-19 10:45:16 +00:00
Steve Lamerton
0e830c7c52 Correctly stop the loading animation in the sample when we veto navigation.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68762 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-17 13:46:09 +00:00
Steve Lamerton
4d0dddc7ad Rename LoadUrl to LoadURL. This corrects the capitalisation as it is an acronym, and brings it into line with GetCurrentURL.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68760 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-17 10:55:59 +00:00
Vadim Zeitlin
ee19ab6d80 Use correct format specifier for thread id in the sample.
Thread id is an (unsigned) long, not just unsigned, so use "%lx" to print it
instead of "%x" to avoid asserts in formatting code.

Closes #13404.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68757 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-17 10:35:29 +00:00
Steve Lamerton
49f07becce Add a menu item linking to a custom scheme example.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68700 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-15 13:10:34 +00:00
Steve Lamerton
c13d6ac1ea Rename wxWebHistoryItem to wxWebViewHistoryItem.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68698 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-15 12:31:31 +00:00
Steve Lamerton
04fa04d806 Rename wxWebNavigationError to wxWebViewNavigationError and wxWebNavigationEvent to wxWebViewEvent. This makes the names more consistent with other parts of wxWidgets.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68697 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-15 11:03:26 +00:00
Steve Lamerton
7d8d6163ad Rename wxWebFileHandler to wxWebViewArchiveHandler, wxWebHandler to wxWebViewHandler. Update the documentation and the sample. Add a constructor taking a wxString to specify the scheme in wxWebViewHandler.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68689 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-14 12:15:34 +00:00
Steve Lamerton
603cfe4218 Add various selection menu items to the sample.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68683 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-13 15:45:39 +00:00
Steve Lamerton
54883129ae Add Run Script menu option to the sample.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68682 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-13 14:53:46 +00:00
Steve Lamerton
10ad4ba669 Add history list to the sample.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68681 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-13 14:11:32 +00:00
Steve Lamerton
70544c1e6c Call Dismiss rather than Show(false) on the infobar to correct the layout.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68679 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-13 10:07:03 +00:00
Steve Lamerton
1c29aacad8 git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68642 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 2011-08-11 12:21:47 +00:00
Stefan Csomor
b8a14a1708 adjusting include styles
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68638 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-11 08:43:38 +00:00
Steve Lamerton
a032168d8c Complete rebake with web libraries to allow easier testing.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68627 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-10 18:32:52 +00:00
Steve Lamerton
94e0018723 Merge in from trunk r64802 - r68625
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68626 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-10 18:10:42 +00:00
Dimitri Schoolwerth
ee7553e935 Added NSApplicationDelegate's openFiles for wxOSX-Cocoa.
openFiles (available since OS X 10.3) replaces using the openFile method. It allows for more convenient handling of multiple drops and knowing in advance how much files/folders are dropped instead of openFile with which you only get to respond to a single file/folder drop at a time. By default openFiles calls the newly added MacOpenFiles which calls MacOpenFile multiple times, so ordinarily the behaviour is backwards compatible (both on wxOSX Cocoa and Carbon).

The openFile instance method has been removed because it doesn't seem to be called anymore: neither when dropping a single file on the application in the dock or Finder nor when passed as a command-line argument.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68617 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-09 22:17:12 +00:00
Vadim Zeitlin
b86ac1efaa No changes, just correct the helpview sample name in comment.
"printing.cpp" was used for whatever reason.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68612 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-09 11:25:09 +00:00
Steve Lamerton
3baf235f60 Use shared pointers to hold wxWebHandlers throughout.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68605 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-08 15:12:33 +00:00
Vadim Zeitlin
ddae52629c Added wxTopLevelWindow::MSWGetSystemMenu() method.
Also generate events corresponding to WM_SYSCOMMAND messages for the custom
items of the system menu.

Add a small snippet to test the new functionality to the dialogs sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68596 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-08 09:32:42 +00:00
Vadim Zeitlin
7112cdd1f3 Add support for wxHELP button to wxMessageDialog.
Implement support for wxHELP for wxMSW, wxGTK and wxOSX/Cocoa (at least when
showing the message box from the main thread, there doesn't seem to be any way
to show more than three buttons with CFUserNotificationDisplayAlert() so
"Help" button is not supported when using it).

This is useful not only on its own, i.e. to allow the user to ask for help,
but also because it brings the total number of buttons supported by the
message dialog to 4, meaning that more choices can be offered to the user
(which is rarely, but not quite never, useful).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68537 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-04 22:53:42 +00:00
Steve Lamerton
75b0b0bcae Hide the infobar in the sample if we start navigating to another page.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68482 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-08-01 14:05:32 +00:00