Skip to content
Loading
How to Print dynamic text on an image and save that image(with text).  
  •                  
      
     
  •           
  •         class="col-md-7">  
  •             class="container my-custom-scrollbar d-inline-block">  
  •               "url" (click)="getcoordinates($event)" style="width: 100%; height: 100%; object-fit: scale-down;">  
  •                 
  •            
  •    
  •  CSS file
    1. .my-custom-scrollbar {  
    2.         position: relative;  
    3.         width: 500px;  
    4.         height: 500px;  
    5.         overflow: auto;  
    6.     }  
    7.       
    8.     .caption {  
    9.         color: red;  
    10.         font-weight: bold;  
    11.     }   
     
    But the positon where user has clicked and position where text is printed are not matching. It does not print text at exact position where user has clicked. So how to pirnt text on image? Also how to save this image with text; at given path? Thank you in advance.

    2 Replies

    Know the answer? Post it — somebody with the same question will find it here.