Provide overrides for header style properties

Bug #1259953 reported by Ken VanDine
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu UI Toolkit
Fix Released
Wishlist
Zsombor Egri

Bug Description

It would be nice to have an easy way to override style properties for things like headers. For example, in system-settings we have a Preview page for confirming your background selection. The design calls for making the image show on the whole screen so you can see what it'll look like when set before confirming. It's great that the header of the page is transparent, and shows the image through. But depending on the color of the image, the title text in the header could be hard read. We've worked around this in system-settings by adding a black rectangle the size of the header and tweaking the opacity to help provide a reliable background for the title text and changing the textColor of the header style to Theme.palette.selected.foregroundText.

The result looks great, but it's a hack. We have to make sure we change the textColor back when the page gets popped off the stack. It would be nice if in the page we could set properties like that. Something like:

Page {
    header.textColor: Theme.palette.selected.foregroundText
    title: "Preview"
   ...
}

This would override the textColor just for this page, not the other pages in the stack.

Tim Peeters (tpeeters)
Changed in ubuntu-ui-toolkit:
status: New → Confirmed
assignee: nobody → Zsombor Egri (zsombi)
Revision history for this message
Tim Peeters (tpeeters) wrote :

You can set Page.head.foregroundColor now, so this will work:

Page {
    head.foregroundColor: "green"
    title: "Preview"
   ...
}

Changed in ubuntu-ui-toolkit:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.