Although one properly can not use masar money to write a Sefer Torah ( as you cant be mekkaim the mitzvah asha with massar ).
Question if one can purchase a kosher sefer torah for $30000 but wants to spend more for nicer handwriting and more chumroes which would cost $50000 can you use massar money for extra $20000 and still mekkaim the Mitzavh asha ?
According to many poskim, the same way we can not use maaser money for the actual sefer torah, since it is our own mitzvah, and we can not use our own money for it, the same would apply to the hidurim of the sefer torah, because it is for our own benefit. Therefore you shouldn’t use maaser money for your own sefer torah. A person that gives a chomesh, may use the extra tenth for a hidur mitzvah.
B’orach Tzedakah 11-5.