How to align a group (instead of text) along a path in svg?

前端 未结 3 791
半阙折子戏
半阙折子戏 2021-01-07 10:06

Lets assume I have programmatically created a circle and some text, that I want to align along the circle. I am able to do so usin

3条回答
  •  梦谈多话
    2021-01-07 11:10

    In addition I have a rectangular image (or any svg group ), that I also would like to align to the circle (see red rectangle in the example image below).

    However, textPath only seems to work for text elements.

    You can use the rectangle unicode character

    In this case you will be able to include it in one textPath command along with other words

    
    
      
    
    
    
     Hello World  
    
                 
    

    You can use any unicode character that suits you

    
    
      
    
    
    
     Hello World  
    
    
                 
    

    If necessary, you can make the animation of the letters

    
    
      
    
    
    
     Hello World  
       
    
                 
    

提交回复
热议问题