Odd styling issue

Forum to discuss the new web client version of Servoy.

Odd styling issue

Postby drookwood » Tue Oct 09, 2018 11:41 am

In NGClient my solution is showing all TEXT_FIELD fields offset to the right and down by about 2 pixels, both in the editor and in the browser. Setting a field to TEXT_AREA removes this offset even though still using the same style for the field.In this screenshot the name field and the account type field are TEXT_FIELD and the code field is TEXT_AREA
Screenshot 2018-10-09 at 10.17.57.png

More bizarrley, using the same solution level css in a testbed solution does not display the same behaviour! Has anyone got any clues as to what is influencing the offset of the TEXT_FIELD fields and why the same style works differently on TEXT_AREA fields? Also, what else might be influencing the styling in my main solution which means it behaves differently with the same stylesheet?
You do not have the required permissions to view the files attached to this post.
David Rookwood

SAN Developer
drookwood
 
Posts: 267
Joined: Tue Nov 11, 2003 7:08 pm
Location: Somerset, UK

Re: Odd styling issue

Postby swingman » Tue Oct 09, 2018 6:14 pm

Hi, are you loading any external HTML containing style sheets?

I'm displaying D3.js graphics inside the NG-Client.

In the Smart Client, where I load the code into a JFX-panel, I can style anything I like, such as the body or html of a D3.graphic using CSS.
Inside the NG client, this causes all sorts of strange effects as it overwrote bits the main css stylesheet. The code for the graphics are in the database, meaning the side-effects would vary depending on which records I visited.
So I had rewrite my D3-css to limit the scope.
Christian Batchelor
Certified Servoy Developer
Batchelor Associates Ltd, London, UK
http://www.batchelorassociates.co.uk

http://www.postgresql.org - The world's most advanced open source database.
User avatar
swingman
 
Posts: 1236
Joined: Wed Oct 01, 2003 10:20 am
Location: London

Re: Odd styling issue

Postby drookwood » Wed Oct 10, 2018 1:26 pm

Hi Christian,

That's a thought - I do load some additional css (from the servoy-webclient/templates/ folder) at runtime for webclient use and I wonder if that's interfering somehow. I had discounted that as a possibility due to the fact that I'm seeing the styling changes in developer and thought the additional stylesheet would not come into play until called at runtime but maybe...
David Rookwood

SAN Developer
drookwood
 
Posts: 267
Joined: Tue Nov 11, 2003 7:08 pm
Location: Somerset, UK

Re: Odd styling issue - solved

Postby drookwood » Tue Oct 16, 2018 4:35 pm

Got this sorted out - I am using a separate stylesheet for the login solution and that was overriding the main solution stylesheet with styles of the same name. The login solution still had margins set for the default field class and that was causing the weird offset. Removing those sorted it out.
David Rookwood

SAN Developer
drookwood
 
Posts: 267
Joined: Tue Nov 11, 2003 7:08 pm
Location: Somerset, UK


Return to Servoy NGClient

Who is online

Users browsing this forum: No registered users and 2 guests