Working with VisualStudio 2010 SP1 C#, .Net4.0, Visual Source Safe, Windows7
I am working on the same project with a co-worker in Austria, I am currently in Switzerland. When I click on a form in VisualStudio that my co-worker has created, the .resx file is instantly modified. All the label sizes in the file are some how automatically modified. All the controls in the form are then shoved up into the left hand corner of the form. This makes it impossible for me to edit any of his forms.
Could this have something to do with language localization? A hiden setting somewhere in VisualStudio, that automatically tries to adjust label sizes?
Maybe a .Net configuration or someother windows configuration?
That's because of an auto-generated assignment in the form's Designer.cs file, it would look similar to this:
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
When your co-worker creates a form, the values here are different. That's because he runs the video adapter in his machine with a different resolution, the dots-per-inch setting doesn't match yours. A very common setting is 96 dpi. But operating systems like Vista and up make it very easy to change this setting, it looks like a ruler. With common stops at 125% (120 dpi) and 150% (144 dpi).
Changing this setting makes it easier to read text, a program will use a larger font (measured in points, 1 point = 1/72 inch) on a video adapter with a higher DPI setting. But that also requires controls like Label and TextBox to get larger in pixels to still fit the text. Which is done automatically, that's why you see the form's .resx file change if you enabled localization.
This is an excellent way to ensure that your design will still look good on machines with another dpi setting. But it can be a bit of a pita when you are designing between the two of you. No real fix for that, other than agreeing on a dpi setting.