TextAlign on buttons fails with 2 line text
tmr
✭
in ScreenMaker
Using ScreenMaker included with RS 5.13.01
Add button to screen with size 80,80
Enter text "Index No Weld"
Set font to TpsFont12b
Set TextAlign to "MiddleCenter"
The problem is that with a button this size, the text wraps to 2 lines. For some reason the display ignores the text alignment of center and makes it left. Why does it do this? Is there a way to center this text? Is there a way to insert a line feed (LF) or carriage return (CR) in the text?
Add button to screen with size 80,80
Enter text "Index No Weld"
Set font to TpsFont12b
Set TextAlign to "MiddleCenter"
The problem is that with a button this size, the text wraps to 2 lines. For some reason the display ignores the text alignment of center and makes it left. Why does it do this? Is there a way to center this text? Is there a way to insert a line feed (LF) or carriage return (CR) in the text?
0
Comments
-
Hello,Button Text Alignment does not seem to work very well when the size of the button is small as in your case. The text is wrapped by default in Button control and .NET Compact Framework does not directly support alignment of text in button control.Possible solutions:1. May be you can think of re-phrasing the text.2. Increasing the size of the button3. Try using TpsLabel instead of Button Control to see if the text alignment meets your requirements. Click event can be defined for TpsLabel and states of the control can be changed as well similar to button control.Thanks0
Categories
- All Categories
- 5.5K RobotStudio
- 396 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 250 ScreenMaker
- 2.8K Robot Controller
- 316 IRC5
- 61 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 798 RAPID Programming
- AppStudio
- 3 RobotStudio AR Viewer
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 5 Job listings