Sunday, April 15, 2018

On designing TextBoxes in a Universal Windows Platform projects

I will be describing two aspects of the design. The first one deals with providing adequate space between textboxes when you have more than one. The second deals with designing textboxes so that they have the same style regarding back gorund color: font size and font family.

Controlling space between controls

The easiest way is use the Margin in your control.

The syntax is Margin="left, top, right, bottom"

The next image shows code and design time layout where all textboxes have some space between them. The Button is still attached to the last textbox.

Continued here.

Styling textboxes for uniformity

All textboxes having the same properties such as font style, font size, bordering etc. is essential for making apps to have a good visual appeal.

There are various ways you can do it, but here is a simple example of doing it.

I will be using the example in my previous post as it will simplify writing for me.

I will be using the layout in the next image from my above post:


PlaceSpaceBetweenControls..._2

This is how you modify the XMAL markup for the MainPage.xaml

Continued here.


No comments:

DMCA.com Protection Status