Misfeature: 1px black line / geom. figures, sugg. solution 'pixelsnap' don't work
Hi,
I found inkscape the best open gfx app.
All the more gelastic it was that it's not possible to draw the popular black line of 1px width in true plain black color without having to load an extension (pixelsnap) which did not function in my poor case.
Could we have both the smoothness (?anti-aliasing or underlying between-pixels grid?) and the crispyness optionally available.
I guess, in general this preperfect-feature comprises all cases in which thin-lined crisp geometric figures are wanted.
Cheers, Julius
On Sun, May 19, 2013 at 4:51 PM, Julius Voigt <juliusvoigt@...889...> wrote:
Hi,
I found inkscape the best open gfx app.
All the more gelastic it was that it's not possible to draw the popular black line of 1px width in true plain black color without having to load an extension (pixelsnap) which did not function in my poor case.
Could we have *both* the smoothness (?anti-aliasing or underlying between-pixels grid?) *and *the crispyness optionally available.
Potentially? Yes. Realistically? It's hard to say.
Consider this. A path with a 1px stroke always needs a .500 coordinate, X or Y, to perfectly fit the pixel grid (because the stroke is split 50%+50% around the path). Same about 3px, 5px, 7px, and so on.
Theoretically it's possible to read the current stroke width value and apply a special snapping case, but I fear that it's likely to introduce poor programming practice and poor usability.
Alexandre Prokoudine http://libregraphicsworld.org
On 19-5-2013 14:51, Julius Voigt wrote:
Hi,
I found inkscape the best open gfx app.
All the more gelastic it was that it's not possible to draw the popular black line of 1px width in true plain black color without having to load an extension (pixelsnap) which did not function in my poor case.
Could we have both the smoothness (?anti-aliasing or underlying between-pixels grid?) and the crispyness optionally available.
I guess, in general this preperfect-feature comprises all cases in which thin-lined crisp geometric figures are wanted.
What might help you is using a 1px-grid. If you set the origin of a 1px-spacing grid to (0.5,0.5) px, and disable the "snap to visible lines only", all your lines will snap to center-of-pixel locations which you need for your crisp 1px lines. Inkscape's icons.svg uses a similar technique that you can have a look at. If you don't like looking at a grid the whole time, you can make it invisible, but have it still enabled for snapping.
Cheers, Johan
El 19/05/13 11:04, Johan Engelen escribió:
On 19-5-2013 14:51, Julius Voigt wrote:
Hi,
I found inkscape the best open gfx app.
All the more gelastic it was that it's not possible to draw the popular black line of 1px width in true plain black color without having to load an extension (pixelsnap) which did not function in my poor case.
Could we have both the smoothness (?anti-aliasing or underlying between-pixels grid?) and the crispyness optionally available.
I guess, in general this preperfect-feature comprises all cases in which thin-lined crisp geometric figures are wanted.
What might help you is using a 1px-grid. If you set the origin of a 1px-spacing grid to (0.5,0.5) px, and disable the "snap to visible lines only", all your lines will snap to center-of-pixel locations which you need for your crisp 1px lines. Inkscape's icons.svg uses a similar technique that you can have a look at. If you don't like looking at a grid the whole time, you can make it invisible, but have it still enabled for snapping.
Hmmm, I bump with this stuff all the time when I'm creating mockups for the web. I eventually got used to activating the grid and zooming in for a closer inspection and look for potential problems, but it adds time.
After reading this, the first thing that came to my mind was adding a new option for grid snapping that toggles between snapping to grid intersections (current) and grid centers so one can quickly fix those issues, but after thinking about it twice, I realized that the actual root of this problems is the lack of stroke positioning in SVG/Inkscape.
Once that problem is sorted, the fuzzy outlines problem will go away. A 1px stroke placed outside the edge will fit the grid perfectly if the vector was snapped to the grid
Gez.
On Sun, May 19, 2013 at 6:04 PM, Johan Engelen wrote:
What might help you is using a 1px-grid. If you set the origin of a 1px-spacing grid to (0.5,0.5) px, and disable the "snap to visible lines only", all your lines will snap to center-of-pixel locations which you need for your crisp 1px lines.
It's a nice solution. Until you want drawing rectangles :)
Alexandre Prokoudine http://libregraphicsworld.org
participants (4)
-
Alexandre Prokoudine
-
Guillermo Espertino (Gez)
-
Johan Engelen
-
Julius Voigt