calc widht on resize in locus diagram