Hi Frank,

Correct, you need to add styles to your document (internal stylesheets or
external stylesheets).

In relation to the selectors (.text, body, ...) I recommend you to google
and read about CSS selectors. Wt just passes these on to the browser.

Best regards,
Wim.


On 30 December 2014 at 22:49, K. Frank <kfrank2...@gmail.com> wrote:

> Hello Wim!
>
> On Tue, Dec 30, 2014 at 11:00 AM, Wim Dumon <w...@emweb.be> wrote:
> > You'll find the definition in DialogExample.C line 66.
>
> Thanks very much -- I should have noticed that myself.
>
> I have a couple of quick follow-up questions:
>
> Just so I understand, does the "internal stylesheet" start out
> empty so that without the calls to styleSheet().addRule() it
> would have no effect?
>
> Also, just a syntax / formatting question about the ".":
> (I'm new to Wt and css).
>
> I see (in DialogExample.C)
>
>    textdiv->setStyleClass("text");
>    styleSheet().addRule(".text", "padding: 4px 8px");
>    styleSheet().addRule("body", "margin: 0px;");
>
> Could someone explain the structure whereby ".text" matches
> "text" (with and without the ".", respectively), and why we call
> addRule with ".text" and "body (with and without the ".", respectively)
>
> > Wim.
>
>
> Thanks again for sorting this out for me.
>
>
> K. Frank
>
>
> > On 28 December 2014 at 16:37, K. Frank <kfrank2...@gmail.com> wrote:
> >>
> >> Hello List!
> >>
> >> I am new to Wt and working with Wt 3.3.3.
> >>
> >> I am working with the example DialogExample.C, and looking
> >> at line 28:
> >>
> >>    textdiv->setStyleClass("text");
> >>
> >> As I understand it, this line uses a style sheet to set some
> >> formatting rules for the WContainerWidget textdiv, and because
> >> DialogExample doesn't load any style sheets, I assume it's using
> >> what the Wt documentation refers to as the "internal stylesheet."
> >> ...
>
>
> ------------------------------------------------------------------------------
> Dive into the World of Parallel Programming! The Go Parallel Website,
> sponsored by Intel and developed in partnership with Slashdot Media, is
> your
> hub for all things parallel software development, from weekly thought
> leadership blogs to news, videos, case studies, tutorials and more. Take a
> look and join the conversation now. http://goparallel.sourceforge.net
> _______________________________________________
> witty-interest mailing list
> witty-interest@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/witty-interest
>
------------------------------------------------------------------------------
Dive into the World of Parallel Programming! The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net
_______________________________________________
witty-interest mailing list
witty-interest@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/witty-interest

Reply via email to