Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Best Practice for drawing lines
Message
Information générale
Forum:
ASP.NET
Catégorie:
Formulaires
Titre:
Best Practice for drawing lines
Divers
Thread ID:
01099235
Message ID:
01099235
Vues:
55
Hi all,

I can do some code like this in a form:
using (Graphics g = this.CreateGraphics())
{
    using (Pen p = new Pen(Color.Gray),
        s = new Pen(Color.White))
    {
        g.DrawLine(p, 200, 200, 600, 200);
        g.DrawLine(s, 200, 201, 600, 201);
    }
}
This gives me an inset line. But, the color doesn't exactly match that of those types of lines found elsewhere in the OS and other apps like the IDE itself. And even at that, this doesn't really seem like it is the right/best way to do this. Hopefully you can tell what kind of line I'm after, so what is the right/best way to do this? And if this method is right, how do I find the right color? It would seem to me that it should be a system color or variation of a system color.

TIA,
Chad
_________________________________
There are 2 types of people in the world:
    Those who need closure
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform