Browser widget background color change

The place to discuss anything and everything about running your LiveCode on Android

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

[-hh]
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2262
Joined: Thu Feb 28, 2013 11:52 pm
Location: Göttingen, DE

Re: Browser widget background color change

Post by [-hh] » Sat Mar 16, 2019 1:58 pm

@Youks.
Nothing complicated. This fades in within 1 second. Shorten the waiting time to have it faster:

Code: Select all

on openCard
  set the htmltext of widget "browser" to \
        "<html><head><style> body{ color:white; font-family:Arial; " & \
        "font-size: 17px;line-height:1.4; text-wrap:normal;}</style>" & \
        "<meta name='viewport' content='device-width, " & \
        "initial-scale=1.0, user-scalable=no'/></head>" & \
        "<body></body></html>"
  repeat with i=254 down to 0
    do "document.body.style.backgroundColor= " & \
          "'rgb("&(i,i,i)&")';" in widget "browser"
    wait 4 millisecs with messages
  end repeat
end openCard
@Richmond.
Setting the ink or the blendlevel doesn't work for native displays.
shiftLock happens

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9388
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Browser widget background color change

Post by richmond62 » Sat Mar 16, 2019 3:48 pm

Setting the ink or the blendlevel doesn't work for native displays.
Aha.

So why the "figgy pudding" is that possibility presented in the Properties Palette?

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7237
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: Browser widget background color change

Post by jacque » Sat Mar 16, 2019 5:55 pm

Just a guess, but try hiding the widget on preopencard, setting the html, and then using "show widget browser in xx milliseconds" in the opencard handler.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Youks
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 135
Joined: Mon Sep 05, 2011 6:08 pm
Location: Qatar

Re: Browser widget background color change

Post by Youks » Sat Mar 16, 2019 8:04 pm

None of the options worked. The best way is to keep the background color of the widget to white .......Anytime different from white the issue is noticeable.

Thx for All.

Post Reply

Return to “Android Deployment”