Tag Archives: labels

Use accelerators on labels and buttons in C#

To place an accelerator on a menu item, you put an ampersand in front of the letter in the menu item’s caption that you want to be the accelerator. At run time, the caption is displayed with the accelerator letter … Continue reading

Posted in miscellany, productivity | Tagged , , , , , , , , , , , | Leave a comment

Make a simple histogram in C#

This example displays a histogram showing the distribution of random values that simulate rolling two 6-sided dice. At design time I gave the program’s form two groups of Label controls across the bottom of the form. The bottommost group displays … Continue reading

Posted in algorithms, controls, graphics, mathematics | Tagged , , , , , , , , , , , , | 4 Comments

Zoom on a graph with XAML code in C#

This example shows how you can zoom on a graph with XAML code only, without using C# code. (The program does use C# code to build the graph. It just doesn’t use any to zoom.) The example Zoom in on … Continue reading

Posted in algorithms, drawing, geometry, graphics, mathematics | Tagged , , , , , , , , , , , , , , , , , , , , , , , , , , , | Leave a comment

Zoom on a graph in WPF and C#

It’s remarkably easy to zoom on a graph in WPF. This example extends the example Let the user click on graph points in WPF and C#. To modify the previous version, you first need to rebuild the user interface a … Continue reading

Posted in algorithms, drawing, geometry, graphics, mathematics | Tagged , , , , , , , , , , , , , , , , , , , , , , , , , , , , , | 2 Comments

Let the user click on graph points in WPF and C#

This example shows how you can let a user click on graph points to display information about the data. (It extends the example Draw a graph with rotated text in WPF and C#.) When the user moves the mouse over … Continue reading

Posted in algorithms, drawing, geometry, graphics, mathematics | Tagged , , , , , , , , , , , , , , , , , , , , , , , , , , , | 1 Comment

Draw a graph with rotated text in WPF and C#

This example shows how you can draw a graph with rotated text. The example Draw a graph with labels in WPF and C# has a DrawText method that makes adding text to a graph relatively easy. This example uses the … Continue reading

Posted in algorithms, drawing, geometry, graphics, mathematics | Tagged , , , , , , , , , , , , , , , , , , , , , , , , , , , | 2 Comments

Draw a graph with labels in WPF and C#

This example shows how you can draw a graph with labels. The previous example Draw a graph with even tic marks in WPF and C# draws a simple graph. This example adds a title and labels to the X and … Continue reading

Posted in algorithms, drawing, geometry, graphics, mathematics | Tagged , , , , , , , , , , , , , , , , , , , , , , , , | 1 Comment