I've faced a problem in Qt where I need to draw lines with borders (I have coordinates for nodes and I am just drawing simple thick line from node to node). Just like this: http://img23.imageshack.us/img23/3596/askej.jpg
At first I tried to draw thicker red line and after that black line, but I got inappropriate connecting as you can see at the image above.
Moreover the idea in which we draw all red lines and after that all black lines won't work as well. The lines can be crossed so with this idea we won't have borders over the crossing another line.
Could somebody help me with this problem, please?
Thanks.
// feel free to show me mistakes in my english too
I have exactly this situation in a GIS app (Merkaartor)
You need to work by layers, where all paths on the same layer will first be drawn red then black.
For instance, layer -1 would be tunnels, you draw them first, red then black, then layer 0 are surface roads, you draw them red then black, then layer 1 are bridges, etc...
This properly render a "map" feeling.
Related
Say I have an image of a rose which I want to trace:
I construct a few curvature shapes with it's stroke weight set to 5 like so:
Say I'd now like to see which stroke is placed over another, is there any way for me to do so?
Say my bottom layered stroke crosses a top layered stroke, it then might draw two little lines across the stroke like so:
Is there any way to set up such functionality? Or mimic it? It would help work like this a ton.
The program could get the order of overlap right by looking at the layer orders, which you would of course have to manually order yourself. But having a feature that enables me to see which shape is on top of which when they're overlapping would be great.
I'm currently coding a design mockup into HTMl and I'm trying to figure out the best way to achieve this look responsively. As you see, there's a purple line that stems from the hero CTA button in the bottom right corner. How would I go about changing the line color when it enters the new section; purple to white?
I thought about making two separate lines, but It's difficult to always have them line up right. I wonder if there's some sort of masking trick?
I added a red circle to show the interlacing I'm having issues with.
Screenshot
I am new to RRDtool. I generated a graph with grid(--grid-dash 1:0), a LINE(LINE1:rt#4e9a06) and I also have the area between the line and the x-axis coloured (AREA:rt#4e9a06 ). I notice the grid still shows up in the colored-area. I am wondering if there is any way to cover the grid with the colored-area.
Also, I am also wondering if there is any good-looking rrdtool samples/examples available online? Thanks.
I have no way of testing this currently, but here's what the documentation says (emphasis mine) :
[-c|--color COLORTAG#rrggbb[aa]]
Override the default colors for the standard elements of the graph.
The COLORTAG is one of BACK background, CANVAS for the background of
the actual graph, SHADEA for the left and top border, SHADEB for the
right and bottom border, GRID, MGRID for the major grid, FONT for the
color of the font, AXIS for the axis of the graph, FRAME for the line
around the color spots, and finally ARROW for the arrow head pointing
up and forward. Each color is composed out of three hexadecimal
numbers specifying its rgb color component (00 is off, FF is maximum)
of red, green and blue. Optionally you may add another hexadecimal
number specifying the transparency (FF is solid). You may set this
option several times to alter multiple defaults.
What about making an almost transparent grid with arguments like these (note the extra 7F parameter which translates to 127 in decimal):
-c MGRID#<hex triplet>7F -c GRID#<hex triplet>7F
It should still be visible in the background but be invisible (or barely noticeable) once any graph covers it.
Note that this answer from the developer of RRDTool says that the grid is always painted after the graph, so in the end you'll always have it in the foreground, your only solution is to either totally disable it or tinker with color/transparency parameters to make it invisible when covered by the graphed data.
Can someone explain to me what is the math behind this pie menu? I don't understand how it's rendered at all. Helps are appreciated
Most of graphics libraries have function like Pie for drawing of circular sector. To draw ring sector, like your bottom picture, one could draw all needed circular sectors with large radius, then circle or circular sector with lesser radius to fill center region.
How can I create a rounded rectangle with a dashed line? I've seen several routines that draw their own straight lines, but nothing for rounded rectangles.
There used to be (probably still is) a great AS 2/3 library for this but I can't find it.
This looks pretty promising:
http://blog.alegitimatebusiness.com/2007/11/07/as2-as3-draw-a-dotted-rounded-corner-box/