Alignment in MonoDevelop - alignment

I switched from using Visual Studio Ultimate 2010 and I am trying to work with MonoDevelop and GTK#. I am trying to use new IDE but it seems much different than Visual Studio.
I want to develop fullscreen application that's why I must set Horizontal and Vertical alignment. In Visual Studio I can set the HorizontalAlignment property to Stretch and VerticalAlignment to Top, but MonoDevelop and Gtk# haven't this property. How can I set the same alignment in MonoDevelop?

The GTK+ layout system very different to Winforms - it's based on packing widgets into containers. By default, most widgets expand to take all the space allocated to them by their parent container. For example, if you put a button directly into a window, it will fill the entire window. If you put it into a HBox/VBox, you can use the expand and fill properties to control how the box shares the available space among its child widgets, and how the widgets fill the available space.
A more exact answer would need some information about the widgets you're actually using.

Related

How to restore/clear form position after multi-monitor setup change

Within the IDE, when F12 toggles between code and form,
the forms are displayed outside the monitor borders,
and therefore not visible.
This happens after a multi monitor setup has changed,
and the forms no longer open within the available new monitor screen areas.
One way to resolve this is to use the property inspector and
set the Top/Left properties to 4 to make the forms visible.
This is however a lot of work,
especially if many forms and possibly many projects are involved.
Is there a better way to reset the form locations once and for all,
so they are all visible with the new monitor setup?
There is nothing (AFAIK) in Delphi 6 IDE that would help. But assuming you are using Windows, the help is near, (tested on Windows 7):
Right-click on taskbar and select 'Cascade windows', this affects all windows in one go.
or
Alt-Tab to the window, press Alt-Space and then M (for move). Move the window with the arrow keys. This you would have to do seperately for each window.
Close your Delphi IDE. Then, if your current project group file is xyz.groupproj, open the file xyz.dsk with an text editor. Look for section [UndockedDesigner] entry "Count" and change its value to zero.
[UndockedDesigner]
Count=0
That will force all design window positions to 0,0 on your main monitor.

Possible to change the scale of form designer (of mobile device simulator)

I'm using FMX framework of Delphi XE6 to develop a webapp for iPad. The form looks extremely large, so that the whole form cannot be shown entirely on 24' TFT monitor. If I want to add control to the form bottom, I have to scroll down first. I found one thing very annoying.
Is it possible to scale the form to 50%? On MacOS, I can easily scale the window of the iOS simulator by pressing ⌘+1.
If you want to fit it too your screensize you schould set the align properties to Client rather then give it a size. This way it scales automaticly to your screensize. If you have more components on your form you should change all of them too align in the way you want and maybe use layouts.

Delphi - how to customize IDE layout

Delphi 2010 - all patches, Win 8.1 64 bit. Reinstalled EVERYTHING... windows,etc, so functionally a new machine. Installed D2010, then installed GExperts and CnPack Wizards, as I had used them both before a really liked them.
I have 2 monitors, so I changed my layout to Classic Undocked. The default is to have the component palette at the top right of the Delphi main window.
In my previous release, I was able to change the HEIGHT of this window to double whatever it is now, and drag the palette UNDERNEATH the glyphs from the File / Edit / Search area, so that way my component palette went across the whole screen. For whatever reason, I cannot do this now. When I move my mouse to the BOTTOM of the delphi window area, I get the "expand window up and down" cursor, like I should, but the window refuses to increase in height. There is some setting preventing me from increasing this windows height, but I can't find it. What setting am I looking for in order to be able to increase the height, so I can drag/drop my palette to the bottom LEFT corner of this window?
Thanks
The size of the main undocked window cannot be modified by resizing it manually. It is sized so that it is exactly large enough to contain its children. So, you can do what you want by moving the component palette to the desired location. When you do so the main window will increase in size so that the component palette fits.
Judging by your screenshot, your toolbars are drawn in a way to indicate that they are locked and cannot be dragged. That's not functionality that is present in the plain vanilla Delphi IDE, so I suspect that you have used functionality from either GExperts or CnPack to lock your toolbars. Obviously you'll need to unlock them in order to move them.
Finally, I should point out that the inability to resize the main window vertically is not new. Classic Delphi versions (e.g. Delphi 7) behaved in exactly the same way. So I think that the fundamental issue is not related to a Delphi version upgrade, but rather is related to you having locked your toolbars.

Updgrading TFS Explorer Custom Control from 2010 to 2012 - rendering differences?

We use TFS 2010 with developers having both VS 2010 and VS 2012. We had created a custom control (both TFS Explorer and Web Access). Since several developers are moving up to using VS 2012 I was updating the TFS Explorer custom control to 2012 as well, but have run into an odd issue dealing with how the two Team Explorers rendering the control.
The control is a windows form control which contains a dropdown list and a button (it does not extend the TFS specific dropdown). There is also a label that appears in some cases, but for the most part when it renders in VS 2010 it looks like this:
See images at: http://social.msdn.microsoft.com/Forums/en-SG/tfsworkitemtracking/thread/e3e254e1-7f56-495c-a3c1-e92bfe030102
The missing white boxes are alterations to the image to redact internal information only.
Note that you can see the full dropdown and the refresh button. This control is compiled with autosize (grow and shrink) with the dropdown and refresh button docked so that when you resize the form it correctly resizes just fine.
For the migration to 2012 I created a new project, moved the control over and updated the references for the Work Item control and Work Item client to the 2012 counterparts. Everything compiled correctly, and the controls work as expected; however, they render poorly.
See images at: http://social.msdn.microsoft.com/Forums/en-SG/tfsworkitemtracking/thread/e3e254e1-7f56-495c-a3c1-e92bfe030102
Note that the control is simply too wide. It cuts off the refresh button completely and a bit of the dropdown is also cut off.
When I resize the window in VS 2012 it also scales "correctly" but it is cut off always in the same place.
The control itself is set up the same way between the two versions, literally all I did was reference the newer TFS related assemblies and recompiled, then deployed to my local 2012 folder to get it to pick it up. Both 2012 and 2010 are pointed to the same TFS 2010 process template. It just appears that the two render the controls different, or are basing the autosize on different values. Is this a bug or some setting I'm not dealing with?
One option for me is to just set the control to a specific size, but I'd rather not do that. Can someone give me a hint as to why these are rendering differently?
UPDATE: In playing around with this is appears that the control is simply sized too large. In VS 2012 it has about 20-30 pixels more space given to it than it does in VS 2010, so when it autosizes it is too big, but then something in the rendering is cutting it off. When I moved the inner controls to provide an empty space on the right of my control then they come into view; however, I've also noticed that as I enlarge the window and then attempt to shrink it back down the control simply doesn't get smaller anymore even though the autosize is set to shrink and grow.
UPDATE: I've posted this to the Connect site since it might be a bug in Studio. http://connect.microsoft.com/VisualStudio/feedback/details/781607/updgrading-tfs-explorer-custom-control-from-2010-to-2012-rendering-differences

Positioning controls in Delphi 5 so they fill the form client area when the form is resized in the same sort of proportions as they did initially

I have a DBGrid above a group box with some buttons and edit fields and another group box below that again with some buttons. I cannot fins a setting for the align and/or anchors for the DBGrid and the group boxes so they fill the form without overlapping or leaving blank bits of form.
I am using Delphi 5 on XP Pro with all updates installed.
If I remember, there is no built-in way to do this. When I did this in Delphi I implemented it manually in the event handler for the form resize event. You can recalculate the new positions for each control based on the size of the form and the proportions of the layout you want. You can simplify it by breaking the form in to panels and setting most of the controls to align to one or more edges of their parent panel. That way you mostly just have to resize a few panels. If you have a complex form you still might need to reposition some individual controls.
You might also find a third-party container control out there which makes this easier. I would search for combinations of "flow", "layout", "table", "container".
We've struggled with this as well, and I agree with Charles M that there is no built-in way to do this.
If you're looking for an outside solution, the ExpressLayout control from Developer Express allows you to fine-tune the positioning of controls on Delphi forms. They advertise "Screen Resolution Independence - Automatically Resizable Interfaces - Look & Feel Standardization...", so it might be worth looking into.
I've never used that particular control, but we use a lot of other Developer Express controls in our commercial projects. The controls and support are excellent.
See: http://www.devexpress.com/Products/VCL/ExLayoutControl/
They don't have a trial version, but do have a 60-day no-questions-asked money-back guarantee.

Resources