Specify the vertical y position of the text in relation to the source image top border.
This parameter will overwrite the vertical position value defined by text-position
.
Values
This parameter accepts positive and negative integers. With negative values placing text outside of the source image boundaries.
If not text-y
value is defined, the vertical position of the text will be defined by text-position
parameter.
Examples
Using text-y=0
will render text on the top edge of the source image:
GET
https://assets.imglab-cdn.net/particles.jpeg?text-y=0
Using a negative value will render text outside source image boundaries. In this example we are using text-y=-20
:
GET
https://assets.imglab-cdn.net/particles.jpeg?text-y=-20
Negative values can be useful if you are adding some padding to the image. For this example we are using text-y=-40
and setting a pading of 40 pixels with padding=40
:
GET
https://assets.imglab-cdn.net/particles.jpeg?text-y=-40&padding=40