Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I draw separators?

I am programming in C, using the Windows API, and would like to know how I could draw separators. I would appreciate a code example.

Edit: Here's an illustration.

alt text
(source: microsoft.com)

like image 735
someguy Avatar asked May 23 '10 17:05

someguy


People also ask

How to draw a horizontal separator in HTML and CSS?

There are many ways to draw a horizontal separator in HTML and CSS. The right way will depend on each case. In this article, I'm gonna show you the main ways to do it. Generally, the HTML tag <hr> (horizontal rule) is a semantic tag that's used to draw a horizontal line, separating elements horizontally.

How do I add a line separator to a paragraph?

Quick visual separators using the keyboard 2. Adding a paragraph border separator for lots more choice There is also a Horizontal Line tool you can use. 1. Position the cursor where the line is to be inserted.

How to add a paragraph border separator in AutoCAD?

Adding a paragraph border separator for lots more choice There is also a Horizontal Line tool you can use. 1. Position the cursor where the line is to be inserted. 2. Select the Home tab | Paragraph group, or Table Tools | Design tab (if you are working with a table). 3. Click the drop-down arrow on the Border icon.

How do you make a divider out of contact paper?

Use contact paper. Measure and cut out a section of contact paper that is double the size of one side of the paper sheet. Remove the backing from the contact paper and slowly cover one side of the paper sheet. Smooth out any bubbles or wrinkles that form. Then enfold the other side of the paper, to cover the divider completely.


2 Answers

Use a static control/window with the SS_ETCHEDHORZ style (This is what explorer does and should give you the most accurate rendering when it comes to Visual Styles)

like image 81
Anders Avatar answered Sep 29 '22 16:09

Anders


I don't suppose you're just looking for LineTo?

For menus and toolbars, generally the separators are drawn for you by the menu and toolbar APIs. For random separators in dialog boxes, etc, like in the picture you added you can just draw a line.

like image 25
Terry Mahaffey Avatar answered Sep 29 '22 15:09

Terry Mahaffey