Displaying type around a curve

Hi Folks, I have read other posts on the topic of displaying type on a curve and it has been established this is not a supported feature, requiring custom solutions. With that in mind, I thought I would share my approach and see if anyone out there has feedback or is willing to share their techniques and/or solutions. 

For my WF, I ended up creating a method for drawing letters with lines and I was able to calculate the letter positioning and rotation as it followed along a given radius. To save on time and effort, I created functions for translating string input into plotting arrays for a given string, radius and angle.  

Here is an example: 

It works ok for the most part with a few exceptions:

  • The initial setup of the font dictionary is time consuming. 
  • The x/y plotting input is based on whole numbers, so there is some minor distortion for small fonts and/or fonts with finer details. 
  • Overall, the final product is not as clean as what can be generated by a font or prerendered background.

Let me know if you have any feedback or questions. 

Thanks!

  • There is only one good working solution with a very big drawback: a custom font - one for each required rotation.

    The big drawback is that you can't preload all fonts at once for a watchface like your example so you have to load/unload the fonts for each rotation which is very expensive but otherwise you'll break memory limits on most devices (maybe on a venu and similar where you have 512kB memory you can keep the fonts in memory)

    With rotated fonts you get smooth and anti aliased letters and can use any font but it's a lot of work to create the fonts

  • Uggh... what a pain. Disappointed

    So, how many versions of the font would you need for a smooth rotation? Not 360 versions, right? 

  • I was thinking about doing something like this.  I'm interested in looking at the code to see if it could be optimized to look any better.