How to avoid the tiny white line between clipped areas and gobbed line width

The is a tiny unwanted white line between blue areas (it is a MWE ;-) ) and the black border line is cut by the clipping line. How to avoid this two problems ?

It's not visible on a png image but very annoying on a pdf.

\documentclass[tikz]{standalone}

\begin{document}
\begin{tikzpicture}

\begin{scope}
\clip[rotate=45] (-1,-1) rectangle (0,1) ;
\draw[fill=blue] (0,0) circle (1) ;
\end{scope}

\begin{scope}
\clip[rotate=45] (1,-1) rectangle (0,1) ;
\draw[fill=blue] (0,0) circle (1) ;
\end{scope}

\end{tikzpicture}
\end{document}

-

Without any rotation, this is what your code gives:

\documentclass[tikz]{standalone}

\begin{document}
\begin{tikzpicture}

\begin{scope}
\clip[rotate=0] (-1,-1) rectangle (0,1) ;
\draw[fill=blue] (0,0) circle (1) ;
\end{scope}
\end{tikzpicture}
\end{document}


The cuts are clearly seen. With some shifts as below:

\documentclass[tikz]{standalone}

\begin{document}
\begin{tikzpicture}

\begin{scope}
\clip[rotate=0] ([shift={(-0.5\pgflinewidth,-0.5\pgflinewidth)}]-1,-1) rectangle ([shift={(0.5\pgflinewidth,0.5\pgflinewidth)}]0,1) ;
\draw[fill=blue] (0,0) circle (1) ;
\end{scope}
\end{tikzpicture}
\end{document}


You can give appropriate shift with a magnitude of \pgflinewidth to your actual code:

\documentclass[tikz]{standalone}

\begin{document}
\begin{tikzpicture}

\begin{scope}
\clip[rotate=45] ([shift={(-\pgflinewidth,-\pgflinewidth)}]-1,-1) rectangle ([shift={(\pgflinewidth,\pgflinewidth)}]0,1) ;
\draw[fill=blue] (0,0) circle (1) ;
\end{scope}

\begin{scope}
\clip[rotate=45] ([shift={(\pgflinewidth,-\pgflinewidth)}]1,-1) rectangle ([shift={(0.5\pgflinewidth,\pgflinewidth)}]0,1) ;
\draw[fill=blue] (0,0) circle (1) ;
\end{scope}

\end{tikzpicture}
\end{document}


In fact 0.5\pgflinewidth would be enough, but to be on safer side \pgflinewidth has been used.

-
You shot too fast ;-) –  Tarass Mar 8 at 15:24
@Tarass Only some times ;) –  Harish Kumar Mar 8 at 15:26
By default the line is drawn on the path. I hoped there was an option like inner to draw the line inside the path, outer to draw the line around the path (cycle) ? –  Tarass Mar 8 at 15:27
@Tarass No, it is only the pgflinewidth –  Harish Kumar Mar 8 at 15:28