Bug 11524 - On the fly code formatting takes effect even when turned off
Summary: On the fly code formatting takes effect even when turned off
Status: RESOLVED FIXED
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Text Editor ()
Version: 4.0.3
Hardware: Macintosh Mac OS
: Normal normal
Target Milestone: ---
Assignee: Mike Krüger
URL:
Depends on:
Blocks:
 
Reported: 2013-04-02 16:36 UTC by Jools Adams
Modified: 2013-04-03 05:47 UTC (History)
1 user (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
It's an almost empty solution to demo the bug (5.05 KB, application/x-zip-compressed)
2013-04-02 16:36 UTC, Jools Adams
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Jools Adams 2013-04-02 16:36:10 UTC
Created attachment 3730 [details]
It's an almost empty solution to demo the bug

You can turn on the fly code formatting off by unchecking Preferences->Text Editor->Behaviour->Enable On The Fly Code Formatting. It's still applied though! For example open the attached solution, check on the fly formatting is off and open Program.cs. Hit return at the end of line 9 (Console.WriteLine ("Hello World!");). Then type "Console.WriteLine(", without the quotes, of course! You must type this out in full and not use auto-complete for WriteLine. A space is inserted before "(". On the fly code formatting should be turned off, so I'd expect that not to happen :(
Comment 1 Mike Krüger 2013-04-03 01:38:47 UTC
You're right that the setting should be respected there.

It's not really on the fly code formatting at that point (it's just inserting a space or not). On the fly formatting is what runs the formatter when typing ';' or '}'. 

Now the formatting setting is respected at that point as well.

For a quick workaround set the formatting style to something different - to Visual Studio .NET
Comment 2 Jools Adams 2013-04-03 05:47:07 UTC
Nice, thanks :)