$length = 100;
$diameter_slider = 5;
$diameter = $diameter_slider + 3;
$slack = 0.6;
$stopper = 3;

$fn = $preview ? 32 : 64;

rotate([0,90,0])
difference () {
cylinder($length + $stopper, $diameter/2, $diameter/2);
translate([0,0,$stopper+0.001])
cylinder($length, $diameter_slider / 2 + $slack, $diameter_slider / 2+ $slack);
translate([-$diameter/2,0,$length/2 + $stopper + 0.001])
cube([$diameter/2,2,$length], center = true);
}