slanted font

Is there a way how to slant weblabel?

https://documentation.xojo.com/index.php/WebStyle

Thanks but there is no slanted approach in webstyle design.

Sorry, my English is not that good, when I read ‘slant’ I was thinking about ‘italics’. Is that a special font?

What I mean is like this picture

link text

Oh, sorry, I don’t know how to do that with weblabel

Doesn’t seem like you can do this using a WebLabel and a WebStyle.

You could do it by drawing the rotated text in a Canvas with code like this:

[code]Dim s As New StringShape
s.Text = “Hello World”
s.TextFont = “Arial”
s.Rotation = -3.14 / 4 // 45 degrees
s.X = 50
s.Y = 50

Dim p As New Picture(100, 100)
p.Graphics.DrawObject(s)
g.DrawPicture(p, 0, 0)[/code]

Would CSS work? https://css-tricks.com/snippets/css/text-rotation/

All CSS properties works.
The problem is that the ide’s WebStyle editor lets you assign only a subset of the available properties.
These limits can be bypassed using code.

[quote=398513:@Paul Lefebvre]Doesn’t seem like you can do this using a WebLabel and a WebStyle.

You could do it by drawing the rotated text in a Canvas with code like this:

[code]Dim s As New StringShape
s.Text = “Hello World”
s.TextFont = “Arial”
s.Rotation = -3.14 / 4 // 45 degrees
s.X = 50
s.Y = 50

Dim p As New Picture(100, 100)
p.Graphics.DrawObject(s)
g.DrawPicture(p, 0, 0)[/code][/quote]
WebCanvas doesn’t support StringShape.

Sure, but web projects do. So the String shape is rendered to a Graphics and then to WebCanvas. Not ideal, though.

Thanks for all response.