cpjamloki
Visitor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-28-2015
09:44 PM
Fitting text alignment under roScreen
Function createOverlayBox(x, y,w,h,a)
black=&h000000FF
font_registry = CreateObject("roFontRegistry")
font = font_registry.GetDefaultFont(19, true, false)
m.screen.DrawRect(x,y, w, h, &hFFFFFFFF)
m.screen.DrawText(a.text,x+10,y+20,black,font)
End Function
in above code i am using roScreen and there is black ractangle is behind my text., which is drawing good but problem is that text is not fitting inside rect it's not wrapping here, because text length is bigger than rect.
is there any solution like imageCanvas(Text Attribute alignment)
1 REPLY 1

TheEndless
Channel Surfer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-28-2015
11:32 PM
Re: Fitting text alignment under roScreen
You'll need to measure the text and clip it yourself. The code here might help: viewtopic.php?f=34&t=64824&p=415822
My Channels: http://roku.permanence.com - Twitter: @TheEndlessDev
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)
Instant Watch Browser (NetflixIWB), Aquarium Screensaver (AQUARIUM), Clever Clocks Screensaver (CLEVERCLOCKS), iTunes Podcasts (ITPC), My Channels (MYCHANNELS)