pen tool fix and some other changes (witch are not compleated)