none
Color - Font - List Box RRS feed

Answers

  • Hi Markus,

    The List View is built on top of jQuery Mobile List View and the style is quite complex so it's better to define your own CSS style to change the List View color. Some examples of the difficulties you will face trying to change color in code is:

    • Each List Item has its own css class style applied, so you cannot simply change the style of the whole List View. You have to change individual List Item css.
    • The postRender call for each row does not pass in the LI element, so you have to call parent() to affect the whole row.
    • Each List Item has background-image defined, so you will need to clear out this css before apply your own background color.

    That's said, on the Screen Designer, you can click on the Content Item under the List View and write its postRender code. Here's an example:

    myapp.BrowseOrders.RowTemplate_postRender = function (element, contentItem) {
        $(element).parent().css({
            "background-color": "green",
            "background-image": "none",
            color: "yellow"
        });
    };

    Best regards.
    Huy Nguyen


    Tuesday, April 2, 2013 7:28 PM