Notifications
Clear all

[Closed] Garbled Label Text

I was using a bitmap for the background colour but whenever it was updated you would see the rollout back colour so I decide to use SetDialogBitmap instead. but now my label text appears garbled whenever it is changed. Anyway to fix this? Thanks.


  
    
  rollout test "Image Button" 
  
  (
  	
  	label Image_Name "" align:#left pos:[200,200]
  	timer clock "Move Timer" interval:1 active:true
  	local val = 100000000
  
  on test open do
  (
  	SetDialogBitmap test (bitmap 400 400 color:white)
  
  )
  
  
  
  on clock tick do
  (
  
  val = val +1111
  Image_Name.text = val as string
  )
  
  
  )
  
  
  
  createDialog test 400 400
  
4 Replies

Hi,

clearing the text in the image_name and then update with the new value will remove the garbled text.

Like this

Image_Name.text = “”
Image_Name.text = val as string

Akram

Thanks for your reply Akram. I already tried that but it causes the text to ‘flicker’ and is a bit anoying when the text is constantly being updated. I also noticed that SetDialogBitmap makes ‘redrawing’ the rollout a bit slower too. For example I have a bitmap that moves and when its moving it dissapears until the rollout has a chance to update the background and then the bitmap.

update bitmap on timer tick too I think it should work !


    
  rollout test "Image Button" 
  
  (
  	
  	label Image_Name "" align:#left pos:[200,200]
  	timer clock "Move Timer" interval:1 active:true
  	local val = 100000000
  
  on test open do
  (
  	SetDialogBitmap test (bitmap 400 400 color:white)
  
  )
  
  
  
  on clock tick do
  (
  
  val = val +1111
  Image_Name.text = val as string
  SetDialogBitmap test (bitmap 400 400 color:white)
  )
  
  
  )
  
  
  
  createDialog test 400 400


Thanks martroyx. Your example didn’t flicker but in my script the entire rollout and all its controls flicker. Oh well. I guess I won’t use SetDialogBitmap.