Hi Paolo,
To customize spacing after a barline or time signature grob (or any other similar grob, like a clef), you can try overriding properties in its space-alist. The first-note property dictates spacing when a grob is next to the first note in a line; the next-note property is for when this happens at any other point in a line.
In the example below, I'm using
fixed-space, but it's just one of many spacing options, all of which can be found in the internals documentation:
http://lilypond.org/doc/v2.20/Documentation/internals/break_002daligned_002dinterface (under
space-alist). The spacing numbers (in staff spaces, I believe) can be changed to whatever looks good to you. Here, I'm just going with zero. If you're curious, you can find the default spacing settings in the internals documentation as well, on each grob's own page (again, under its
space-alist section).
\new Staff \with {
% This first override probably won't be needed, since you usually won't see a barline at the beginning of a line. But just in case...
\override BarLine.space-alist.first-note = #'(fixed-space . 0.0)
\override BarLine.space-alist.next-note = #'(fixed-space . 0.0)
\override TimeSignature.space-alist.first-note = #'(fixed-space . 0.0)
\override TimeSignature.space-alist.next-note = #'(fixed-space . 0.0)
} {
a'1 a'
}
There might be a better / more concise way to do this, but I'm not aware of one at the moment, so I hope this helps in the meantime.
--Owen