Bug 1196356

Summary: RichText style does not change when changing the theme.
Product: [openSUSE] openSUSE Tumbleweed Reporter: David Diaz <dgonzalez>
Component: YaST2Assignee: YaST Team <yast-internal>
Status: RESOLVED DUPLICATE QA Contact: Jiri Srain <jsrain>
Severity: Normal    
Priority: P5 - None CC: ancor
Version: Current   
Target Milestone: ---   
Hardware: Other   
OS: Other   
URL: https://trello.com/c/GV9kfbGw
See Also: https://bugzilla.suse.com/show_bug.cgi?id=1196362
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description David Diaz 2022-02-23 14:05:19 UTC
In the context of "Making the addons selector more 'themeable'"[1] I have found that the RichText CSS is not reapplied when reloading the QSS (aka changing the theme[2])


However, going back and forward after switching the theme makes the RichText to get the right sytle. 

Most probably, the problem is related with the fact that the richtext.css file

> is read by the Y2Styler[3] and set as a default CSS document[4] for the RichText before adding its content.


[1] https://github.com/yast/yast-registration/pull/566
[2] https://github.com/libyui/libyui/pull/64 and https://github.com/libyui/libyui/pull/65
[3] https://github.com/libyui/libyui/blob/ef33bacdb799a103abad8a4ea3cfed0434648792/libyui-qt/src/QY2Styler.cc#L257-L296
[4] https://github.com/libyui/libyui/blob/ef33bacdb799a103abad8a4ea3cfed0434648792/libyui-qt/src/YQRichText.cc#L76-L87
Comment 1 Ladislav Slezák 2022-03-03 09:12:56 UTC
See bug #1196296.

*** This bug has been marked as a duplicate of bug 1196296 ***