Inkscape.org
Beginners' Questions Two shapes next to each other - a thin line
  1. #1
    RamalamaDingDong RamalamaDingDong @RamalamaDingDong
    *

    Hi 

    I have two shapes grouped and put it side by side

    Set stroke width to 0 - but when I use the clip tool a thin line appears 

    also on print

    Can I delete it? Where is the mistake?

    2025 08 28 211730
  2. #2
    Lazur Lazur @Lazur

    Even if the geometry is 100% matching there can be gaps rendered on screen. 

    It's due to anti-aliasing of the edges of the objects, which produce semi-transparent pixels that are atop of eachother. 

    Like, if you have two objects atop eachother with a 50% opacity, the background shows through.

    Horizontal/vertical edges can render gapless at some zoom levels, unlike diagonals/irregular paths.

    It affects only a 1 px area on screen. 

     

    In print? It's up to the printer how to handle the task. It has a RIP that processes every content into solid inkblots -there is no anti-aliasing there. 

    If the resolution is increased, the rendering issue should appear smaller.

    My guess the same applies to the printer -which should already produce a cleaner image, 

    because the current screen resolutions are around 90-100 dpi roughly and the printers start at 300 ppi.

    Altough with printers testing two solid rectangles with black fills would create the cleanest "edge" between.

     

    By the look of the screenshot we cannot tell though if those objects really share the same geometry.

     

    If you want to make it gapless, the best way is to avoid the gap by overlapping the objects.

     

    There are some other cheap solutions like duplicating those two a few times, which will pile up more of the semi-transparent pixels.

    Theoretically that'd still render faulty but usually making 3 copies does the job. 

     

    Other option would be oversampling. Creating a raster copy at a high resolution and using that. 

    The size of the gap will still be 1 px, but that's smaller compared to the full size.

  3. #3
    Paddy_CAD Paddy_CAD @Paddy_CAD

    No mistake. Antialiasing.

    Your screen and your printer have square pixels. Rendering a smooth vector curve in this grid results in a stepped boundary or "jaggies". Antialiasing improves the visual appearance, softening sharp edges by slightly burring the boundary. Blurring, of course, fades the foreground colour into the background. Where two blurred edges meet, these blurred pixels allow background colours to bleed through.

    In your case, the white canvas shows up as a fine line between two rectangles. What you see is an unfortunate side effect of a deliberate design choice. This isn't a bug and it isn't unique to Inkscape. There are some workarounds.

    This is the simplest and one I use regularly. Stretch one rectangle to overlap the other so that the canvas colour beneath is completely obscured.  

    [File > Export...]  [PNG (*.png)]  [View export format options] (that's the cog wheel icon)  [Antialias: 0]
    This removes antialiaing from exported bitmaps. The default value is 2 and max is 3. This does not change Inkscape's screen rendering.

    [File > Document Properties...]  [Display > Render > Use antialiasing: Off]
    This changes image display inside Inkscape only. Rendering artifacts will return in browsers and other image applications (like Gimp).

    You can suppress svg antialiasing in Inkscape and in browsers by adding the following attribute in the XML editor [shift+ctrl+x]. Bitmap export will still be antialiased.

    Svg Crispedges
Inkscape Inkscape.org Inkscape Forum Beginners' Questions Two shapes next to each other - a thin line