PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Thu Mar 28, 2024 10:44 am

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: Thu Jul 24, 2014 7:03 am 
Offline

Joined: Tue Jun 11, 2013 8:41 pm
Posts: 3
I have a scenario where I have to render a polygon to the pdf, and it needs to be filled with a meaningful color, i.e. if it's Red, that means one thing, if it's yellow that means something else. This is done with a dynamic collection of points, depending on the input to the program. So, for example:

Code:
gfx.DrawPolygon(pen, XBrushes.Yellow, points, XFillMode.Winding);


"points", of course, being an array of XPoint[]. As written above, this makes a beautiful yellow polygon as expected. So then my real problem is that sometimes I want yellow polygons, sometimes red, and sometimes I want to make a polygon red AND yellow (I was imagining a pattern of yellow and red stripes or something to make it obvious that the polygon is both red AND yellow. Anybody have any good ideas of how to either:

a) fill a polygon with a series of stripes of 2 different colors,
OR
b) some other technique to make it clear that a colored background is actually a combination of two other meaningful colors.

PS. I considered something like Red & Yellow make Orange, but figured that wouldn't be clear enough (I have a feeling that many people would be fuzzy on color combination).


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC


Who is online

Users browsing this forum: Google [Bot] and 155 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group