in reply to find the starting character position in a line

The position of the first non-space character is the same as the number of (space) characters preceding it. So:
$line =~ m/^(\s*)/; print length $1;
or if you're allergic to line endings:
print length [$line =~ m/^(\s*)/]->[0];

--
use JAPH;
print JAPH::asString();