Hello! With the battery removed, xfce4-battery-plugin 1.0.5 is displaying "50%%" with two percent signs. Maybe change that to "n/a" or "???". Or make it a single "%" at least, please :) Thanks in advance, Sebastian
Duplication of bug #9594.
(In reply to Raphael Groner from comment #1) > Duplication of bug #9594. Seen that too late, yes. It's a year old. If stuff like that is not fixed for a year, this project needs a new maintainer or a wake-up call.
(In reply to Sebastian Pipping from comment #2) > Seen that too late, yes. Please consider then to close this bug as a duplicate. Thanks to your note about more users being affected. > It's a year old. If stuff like that is not fixed for a year, this project > needs a new maintainer or a wake-up call. Feel free to supply a patch. Wining around and opening as much individual reports as possible about the same already known issue won't help anybody and may be considered as just being spam. Sorry, I don't want to sound unkindly.
(In reply to Raphael Groner from comment #3) > Feel free to supply a patch. I'd do, if it would look like there was a chance that someone would revew and apply it and roll a new release after. 1.0.5 is two years old and I hate to code for the trashcan. > Wining around and opening as much individual > reports as possible about the same already known issue won't help anybody As I said, I've seen it after opening the bug. I didn't expect such five-minute-fix to be know and not fixed. > and may be considered as just being spam. Sorry, I don't want to sound > unkindly. But you do. If you review, apply, release, I make you a patch and we have a deal. *** This bug has been marked as a duplicate of bug 9594 ***
(In reply to Sebastian Pipping from comment #4) > (In reply to Raphael Groner from comment #3) > > Feel free to supply a patch. > > I'd do, if it would look like there was a chance that someone would revew > and apply it and roll a new release after. 1.0.5 is two years old and I > hate to code for the trashcan. > > > > Wining around and opening as much individual > > reports as possible about the same already known issue won't help anybody > > As I said, I've seen it after opening the bug. I didn't expect such > five-minute-fix to be know and not fixed. > > > > and may be considered as just being spam. Sorry, I don't want to sound > > unkindly. > > But you do. If you review, apply, release, I make you a patch and we have a > deal. You know, i've tried to have a look at it, and it's not so straightforward. 50%% is displayed because that's the default label set for battmon->charge - which means in certain circumstances, battmon->charge is *not* updated to reflect system state. - probably because gtk_label_set_text(battmon->charge,buffer); line 514 is never called. - probably because if(battmon->options.display_percentage && charge > 0 && !(battmon->options.hide_when_full && acline && charge >= 99)) line 510 is false. Now, to find the reasons... one has to debug it. And that means time. If you're willing to look into it, checking all codepaths, in several distinct situations and make sure that doesnt break other things, great, send me a patch, and i'll gladly apply it, then roll a 1.0.6. Calling this code 'trashcan' is unkindly too, esp when lots of different ppl spent time on it in the past years.
Hello again, > Calling this code 'trashcan' is unkindly too, esp when lots of different ppl > spent time on it in the past years. By "to code for the trashcan" I meant that writing a patch with little hope on someone looking at it, would be like coding to the trashcan directly: that would apply to any project. By no means I intended to call this project a trashcan. I have been a happy a happy user of the battery plugins and XFCE in general for quite a while now. Sorry, I could have said it more clearly. (In reply to Landry Breuil from comment #5) > You know, i've tried to have a look at it, and it's not so straightforward. > > 50%% is displayed because that's the default label set for battmon->charge > - which means in certain circumstances, battmon->charge is *not* updated to > reflect system state. > - probably because gtk_label_set_text(battmon->charge,buffer); line 514 is > never called. > - probably because if(battmon->options.display_percentage && charge > 0 && > !(battmon->options.hide_when_full && acline && charge >= 99)) line 510 is > false. Now, to find the reasons... one has to debug it. And that means time. > > If you're willing to look into it, checking all codepaths, in several > distinct situations and make sure that doesnt break other things, great, > send me a patch, and i'll gladly apply it, then roll a 1.0.6. I see, so it's two different issue combined then: * double percent rather than a single one in the default text * the default text shown while (if I understand you correctly) it should not be, despite lack of a battery I didn't expect the latter.
Double %% is "normal" and has always been there: http://git.xfce.org/panel-plugins/xfce4-battery-plugin/tree/panel-plugin/battery.c#n698
(In reply to Landry Breuil from comment #7) > Double %% is "normal" and has always been there: > http://git.xfce.org/panel-plugins/xfce4-battery-plugin/tree/panel-plugin/ > battery.c#n698 I get why double percent is normal in "%d%% " but "50%%" is not used a sa format string. Why would double percent be normal in display to the user? The plugin is not showing it twice with live percentages and I don't know why users would want it twice, either :)