Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Drawing lines and rectangles #107

@FraserElectronics

Description

@FraserElectronics

I would like to draw a one pixel width rectangle on my D2DControl surface using DrawRectangle with the default stroke width of 1.
However, the rectangle is two pixels wide on my monitor and seems to be a blend of the foreground and background colours.

5

The line should be Red i.e. R:255,G:0,B:0 but you can see it is not.
Two questions:

  1. How to I get a single pixel line (is this related to DPI as per my previous issues)?
  2. How to not blend the pen colour with the background colour?

Andy

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions