Commit Graph

52729 Commits

Author SHA1 Message Date
Stefan Csomor
4b1d0dbe25 fixing iterator use
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67213 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 07:18:25 +00:00
Stefan Csomor
616c7cbd92 replace usage of objective-c keyword 'id'
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67212 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 07:16:10 +00:00
Stefan Csomor
e3b2f973e8 replace usage of objective-c keyword 'id'
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67211 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 07:06:43 +00:00
Stefan Csomor
163b01c128 replace usage of objective-c keyword 'id'
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67210 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 07:00:59 +00:00
Stefan Csomor
68ebe5a07f making conversion explicit silences deprecation warning
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67209 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 06:57:03 +00:00
Stefan Csomor
0f54a3be55 signed/unsigned warning fix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67208 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 06:49:51 +00:00
Stefan Csomor
1cf59cb178 signed/unsigned warning fix
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67207 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 06:40:07 +00:00
Stefan Csomor
c1ec7ee8a1 replace usage of objective-c keyword 'id'
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67206 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 06:36:43 +00:00
Stefan Csomor
a624c97f0a silence incorrect warning about missing return value
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67205 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-16 06:34:20 +00:00
Stefan Csomor
31c659e82e fixing iphone build
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67204 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-15 20:21:39 +00:00
Dimitri Schoolwerth
fdb7d5bbc2 Changed behaviour of wxImageResizeQuality parameter in wxImage.Scale and wxImage.Rescale.
Made the following changes:

* Formerly specifying to resize using wxIMAGE_QUALITY_BICUBIC or wxIMAGE_QUALITY_BILINEAR could result in the ResampleBox method being used. Now always resize with the method that the user actually specified.

* Added wxIMAGE_QUALITY_BOX_AVERAGE to explicitly allow resizing with the ResampleBox method.

* Previously wxIMAGE_QUALITY_HIGH was equal to wxIMAGE_QUALITY_BICUBIC. It has been changed to use wxIMAGE_QUALITY_BOX_AVERAGE when reducing the size of an image and wxIMAGE_QUALITY_BICUBIC in all other cases.

Closes #12845.



git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67203 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-15 16:42:34 +00:00
Dimitri Schoolwerth
41774f1b20 Changed wxImage.ResampleBox to always use a box size of at least 2 by 2 pixels.
Previously when resizing by more than 50% (for example resizing from 100x100 to 51x51 or 140x140) a box size of 1x1 would be used which effectively would give the same result as using nearest neighbour. Make sure that at least a box size of 2x2 pixels is always used.

Patch by scottb, see also #12845.



git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67202 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-15 16:37:04 +00:00
Vadim Zeitlin
bd448041e7 Always use icons with wxToolbook in the notebook sample.
wxToolbook asserts and doesn't work if it has no images so always use them
with it in the sample to avoid it.

Closes #11656.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67201 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-15 11:10:46 +00:00
Vadim Zeitlin
825ce0af4f Use consistent sizes for all icons used in the button page of widgets sample.
Explicitly pass wxART_BUTTON to wxArtProvider to ensure that all the icons are
returned in the same size, otherwise they didn't look well and could result in
an assert too, see #12909.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67200 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-15 11:10:42 +00:00
Vadim Zeitlin
cb7ef329e7 Fix setting tooltips for generic wxSpinCtrl.
Forward the tooltip set for the control to its subcontrols.

Closes #9817.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67199 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-15 11:10:38 +00:00
Vadim Zeitlin
8c40af9430 Document wxEVT_COMMAND_SLIDER_UPDATED in wxSlider documentation too.
This even was only documented in wxCommandEvent documentation but not in
wxSlider, mention it there too.

Closes #12292.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67198 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-15 11:10:34 +00:00
Vadim Zeitlin
1f4d7e441c No changes, just clean up wxSVGFileDC code a little.
Use literal strings instead of macros such as "newline", "space" and
"semicolon" and also use wxColour::GetAsString() instead of reimplementing it.

Closes #13037.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67195 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 23:25:58 +00:00
Vadim Zeitlin
8864388cf2 Show wx{Note,Tool}book-specific styles in the notebook sample too.
Demonstrate the use of styles such as wxNB_FIXEDWIDTH or wxTBK_HORZ_LAYOUT
specific to particular controls and not only the ones common to all of them.

Closes #13036.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67192 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:55:05 +00:00
Vadim Zeitlin
5c16a69952 Don't generate wxEVT_CHAR_HOOK events while the mouse is captured.
This prevents the parent TLW from interfering with the keyboard handling of
the window that captured the mouse which very often needs Escape for itself to
cancel the capture.

In particular, this fixes the problems with Escape closing the entire dialog
containing the controls instead of closing just the combobox drop down or a
popup menu in wxMSW.

Also modify wxGTK for consistency and update the documentation.

Closes #12952.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67191 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:55:01 +00:00
Vadim Zeitlin
ff45048665 Document EVT_CHAR_HOOK.
Explain that it is sent to the active TLW and not the focus window and that
handling it suppresses all the normal keyboard events.

Mention that it is not generated by wxOSX/Cocoa currently, see #12431.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67190 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:54:55 +00:00
Vadim Zeitlin
982bc2e421 Don't intercept Escape key while IME is active.
Escape is used by IME and intercepting it at wxWidgets level to generate
EVT_CHAR_HOOK breaks the IME UI and may result in unexpected loss of data
entered by user.

To work around this, don't generate EVT_CHAR_HOOK for Escape while IME is
active by checking for the special semaphore variable (which could be also
used for other things in the future, see #9102) value.

Closes #11386.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67189 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:54:51 +00:00
Vadim Zeitlin
caef3ffacc Produce correct SVG files in all locales.
Using wxSVGFileDC in locales using comma as decimal separator resulted in
invalid SVG files being created as a decimal period should always be used in
them.

Fix this by replacing "%g" format specification with wxString::FromCDouble()
call (wrapped in a convenient NumStr() helper function).

Closes #12008.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67188 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:54:43 +00:00
Vadim Zeitlin
ce39ca74bc Fix changing the size of the bitmaps in wxMSW wxButton.
The size of the wxImageList used to store the bitmaps wasn't updated before
and so the old bitmap size continued to be used even after changing the actual
bitmaps.

Recreate wxXPButtonImageData to ensure that the image list size does change.

Closes #12909.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67187 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:54:39 +00:00
Vadim Zeitlin
32eec436ed Print everything by default in non-interactive mode.
IF we don't show the dialog allowing the user to select the pages range, we
should print everything by default instead of printing nothing at all as we
used to do.

Closes #12998.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67186 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:54:35 +00:00
Vadim Zeitlin
b95a7c3144 Allow wxThread::Wait() and Delete() to block, even under wxMSW.
Add "wait mode" parameter to these methods which can be used to make them
block even under wxMSW where they currently dispatch messages when called
which can be totally unexpected.

Do keep the old behaviour for compatibility however, although it will change i
3.2.

Closes #12998.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67185 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:54:32 +00:00
Vadim Zeitlin
31dcbd12ef Respect alignment flags for owner-drawn buttons in wxMSW.
Honour wxBU_{LEFT,RIGHT,TOP,BOTTOM} flags for owner drawn buttons too, this
ensures that you can both change the colour and align the text differently for
buttons under XP and later.

Closes #12995.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67184 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 11:54:26 +00:00
Julian Smart
2631773e82 Added initialisation and checks
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67182 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-14 10:27:01 +00:00
Vadim Zeitlin
fd3a4cb92d Added precision parameter to wxString::From[C]Double().
Optionally support fixed precision in wxString::FromDouble() and FromCDouble()
methods. This is mostly useful for the latter to be able to format numbers in
portable way (using dot as decimal separator) without loss of precision but
also do it for the former for consistency.

Closes #12973.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67181 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-13 13:53:54 +00:00
Vadim Zeitlin
17a8f66c75 No changes, just correct a wrong trailing comment in #else.
The test meaning was inverted.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67180 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-13 13:53:51 +00:00
Vadim Zeitlin
50a2a3553a Document wxTE_MULTILINE support in wxTextEntryDialog.
It wasn't immediately obvious that this dialog could be used for multiline
text entry too so mention it explicitly in the documentation.

Also show this in action in the dialogs sample.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67179 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-13 13:33:12 +00:00
Stefan Csomor
90dad08e77 add external utf16 text type explicitely, as it otherwise gets treated like plain-text
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67174 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-12 15:57:37 +00:00
Stefan Csomor
e9020f0b22 supporting 24 and 64 sizes via scaling up
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67170 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-11 19:54:44 +00:00
Stefan Csomor
8383e673b1 under cocoa a too-small static box leads to erroneous layout information, therefore use fixed code layout info, fixes #13006
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67168 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-10 18:56:58 +00:00
Stefan Csomor
bda7c3535e safeguard against not-yet-shown view which leads to crashes under OSX
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67167 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-10 18:55:55 +00:00
Paul Cornett
89c6e02442 add wxEVT_MAXIMIZE support to wxGTK
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67164 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 17:22:43 +00:00
Vadim Zeitlin
9bfdedfb3e Make brush hatches in wxGTK consistent with wxMSW.
The cross, vertically and horizontally hatched brushes used 4 pixels between
the hatches in wxGTK but 7 in wxMSW which was very noticeable. Use the same
pattern in wxGTK as MSW uses (as we can't change it there anyhow).

Closes #13029.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67163 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 16:35:56 +00:00
Vadim Zeitlin
65303ed7eb Correct the name of the header for GTK+ < 2.14.
Remove the extra ".h" suffix added during recent GTK+ 3-related changes.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67162 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 16:35:51 +00:00
Vadim Zeitlin
1910265f82 Add tests of other hatched brushes to the drawing sample.
Test wxCROSS_HATCH, wxVERTICAL_HATCH and wxHORIZONTAL_HATCH brushes and not
only the wxCROSSDIAG_HATCH one.

See #13029.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67161 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 16:35:46 +00:00
Vadim Zeitlin
8fa11bb2a2 Don't pop up annoying message box in the drawing sample.
The rubber banding selection message box was shown even after a simple click,
i.e. when nothing was actually selected which was quite annoying, so don't do
this.

Also remove unnecessary casts and use wxLogMessage() instead of
wxString::Printf() + wxMessageBox().

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67160 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 16:35:43 +00:00
Vadim Zeitlin
621d922ffd Corrections to wxTextCtrl::HitTest() documentation.
Fix the signature of the overload returning row and column which got corrupted
during transition to Doxygen and document the overload returning the position
as well. Also document all the parameters.

Closes #12954.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67159 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 10:07:58 +00:00
Vadim Zeitlin
99f44d9704 Send wxEVT_COMMAND_DATAVIEW_CACHE_HINT to proper window.
The event was sent to wxDataViewCtrl parent instead of the control itself for
some reason, fix this.

Closes #13020.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67158 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 09:44:03 +00:00
Vadim Zeitlin
e22e5ee4e7 Mention that wxEVT_MAXIMIZE is only generated by a few ports.
Currently only wxMSW, wxOSX/Cocoa and wxOS2 generate this event. Notably wxGTK
does not.

See #13022.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67157 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 09:40:08 +00:00
Vadim Zeitlin
042959df5d Correct EVT_MAXIMIZE macro name in wxTLW documentation.
EVT_ACTIVATE was mistakenly used instead.

See #13022.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67156 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 09:40:04 +00:00
Vadim Zeitlin
ba7bc4e4e6 Fix search for item by text in wxMSW wxListCtrl.
LVN_ODFINDITEM handler could enter infinite loop if its selection was 0 and a
key not matching any of the items first letters was pressed.

Rewrite the loop in a simpler form to ensure that it is correct. Also clarify
some comments. Finally, fix the behaviour when no matching item was found (if
it didn't hang in infinite loop, it used to select the first item in the
control).

Closes #13026.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67155 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 09:28:41 +00:00
Vadim Zeitlin
aab1681669 Don't assert if starting search position in LVN_ODFINDITEM is invalid.
Just use wxLogDebug() if this happens, asserting here is not the right thing
to do as it doesn't indicate an error in the program but rather invalid
external input and, moreover, we can recover from it easily.

No changes in behaviour in normal case.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67154 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-09 09:28:34 +00:00
Vadim Zeitlin
f382836f40 Add another missing #if wxUSE_MARKUP check.
The definition of DoSetLabelMarkup() should only be compiled when
wxUSE_MARKUP==1.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67151 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-08 17:22:15 +00:00
Vadim Zeitlin
ff65c0ef06 Czech translation update from Zbynek Schwarz.
Fix some incorrect terms.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67150 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-08 17:22:08 +00:00
Stefan Csomor
74518cea41 support app activated and deactivated events, also bring back float_on_parent windows to normal level on deactivate to avoid behaving like stay_on_top
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67146 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-07 20:26:40 +00:00
Stefan Csomor
9d243a476a window level support
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67144 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-07 19:04:55 +00:00
Stefan Csomor
e9e8b38179 bracket unused function
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@67143 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2011-03-07 17:31:19 +00:00