Re-enable automatic substitutions in wxTextCtrl on OS X
This reverts ill-advised commitsc07523734f
and8d42890df4
that disabled native OS X behavior of substituting dashes and quotes with typographically correct characters if the user has this feature enabled. This was a bad idea for two reasons: 1. It made wx applications behave non-natively, and thus be worse, in a highly noticeable area. 2. It made it impossible for applications that want to behave correctly to restore the native behavior, because once setAutomaticDashSubstitutionEnabled or setAutomaticQuoteSubstitutionEnabled is called (as wxTextCtrl constructor does), it's no longer possible to obtain its original, default setting. It's not better to disable native functionality by default, it's better to be native and make customizations possible. wxWindow API exposes access to the native control and if an application desires to disable substitution behavior, it can easily do so from user code. See also #186 and #241.
This commit is contained in:
@@ -620,8 +620,6 @@ wxNSTextViewControl::wxNSTextViewControl( wxTextCtrl *wxPeer, WXWidget w, long s
|
||||
[tv setVerticallyResizable:YES];
|
||||
[tv setHorizontallyResizable:hasHScroll];
|
||||
[tv setAutoresizingMask:NSViewWidthSizable];
|
||||
[tv setAutomaticDashSubstitutionEnabled:false];
|
||||
[tv setAutomaticQuoteSubstitutionEnabled:false];
|
||||
|
||||
if ( hasHScroll )
|
||||
{
|
||||
|
Reference in New Issue
Block a user