FS#17225 - [initscripts] /etc/rc.d/functions explicit draws black backgrounds.

Attached to Project: Arch Linux
Opened by Simon Gomizelj (simongmzlj) - Saturday, 21 November 2009, 05:08 GMT
Last edited by Aaron Griffin (phrakture) - Wednesday, 25 November 2009, 17:58 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Aaron Griffin (phrakture)
Thomas Bächler (brain0)
Architecture All
Severity Very Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:
The various helper functions in /etc/rc.d/functions explicitly draw text on a black background. At boot, this is not necessary as the background is already solid black. However, when running a terminal emulator that supports custom colour schemes and transparency, this behaviour can make manipulating daemons somewhat fuggly, as the background colour or transparency is no longer honoured.

The attached patch file should resolve this issue, it does two things:
1. Remove the explicitly stated black background
2. Reset the terminal colour and then set just the bold attribute, as opposed to explicit drawing white bold text

The new behaviour appears to behave just like it currently does when dealing with white on black, while degrading gracefully for other colour schemes.

Additional info:
* package version(s)
* config and/or log files etc.


Steps to reproduce:
1. Change to a non-standard colour scheme (eg, black text on white background), run something like /etc/rc.d/mpd restart. The output should be invisible.
This task depends upon

Closed by  Aaron Griffin (phrakture)
Wednesday, 25 November 2009, 17:58 GMT
Reason for closing:  Duplicate
Additional comments about closing:   FS#16996 
Comment by Simon Gomizelj (simongmzlj) - Saturday, 21 November 2009, 05:19 GMT
Opps, my bad. Small mistake in that patch file. printhl prints blue.
Comment by Gerardo Exequiel Pozzi (djgera) - Saturday, 21 November 2009, 06:03 GMT
Please attach an unified diff format (diff -u). Thanks
Comment by Simon Gomizelj (simongmzlj) - Saturday, 21 November 2009, 06:26 GMT
Okay, sorry.
Comment by Thomas Bächler (brain0) - Saturday, 21 November 2009, 11:16 GMT
There is another bug report about this with a proposed patch,  FS#16996 . Dan reviewed it and found it good mostly. I don't have time to get into this right now, but we might want to close this as a duplicate. Simon, does the patch from  FS#16996  solve your problem?
Comment by Glenn Matthys (RedShift) - Saturday, 21 November 2009, 14:28 GMT
Actually the black backgrounds were explicitly introduced for people with white background on black foreground terminals not seeing all messages from the rc.d scripts.
Comment by Simon Gomizelj (simongmzlj) - Saturday, 21 November 2009, 20:58 GMT
I'll give the other patch a go, but it doesn't seem to get rid of the black background completely (there are some ;40's).

@Glenn Matthys (RedShift)
My patch address that. For people with a white background on black foreground, it appeals as black text on white, it doesn't force the white on black look. The text becomes green on a green on black term.

Instead of drawing the message lines as bold white text, I changed it them to reset the colour and just draw bold. This respects the terminals set foreground colour without needing to resort to a explicit background, while still maintaining the current look during boot.

I attacked a screenshot as an example of what my patch does over different terminals.
Comment by Simon Gomizelj (simongmzlj) - Saturday, 21 November 2009, 20:59 GMT
Sorry, meant to attach to above.
Comment by Simon Gomizelj (simongmzlj) - Saturday, 21 November 2009, 21:43 GMT
The other patch does archive the same effect. This bug report may be closed as a duplicate.
Comment by Aaron Griffin (phrakture) - Wednesday, 25 November 2009, 17:56 GMT
See  FS#1186  (wow, that's an old bug report)

The gist of it is: by DEFAULT the rc.d output is unreadable on many default terminals that use a white background.

I will happily remove the black background if someone can come up with a colorscheme that works on a default gnome-terminal (or something else with a white background and default colors) as well as the linux console.
Comment by Aaron Griffin (phrakture) - Wednesday, 25 November 2009, 17:58 GMT
Going to close this in favor of the older bug at  FS#16996  - sorry for the noise. Please move discussion there

Loading...