Giter Club home page Giter Club logo

percentage's Introduction

percentage

See your battery percentage in the Windows 10 system tray

Installing

  1. Download the latest release
  2. Put percentage.exe in your startup folder
    1. To get to your startup folder, press Windows+R, type "shell:startup", then press enter

Compiling

This project was compiled with Visual Studio Community 2019.

Select ".NET desktop development" when setting up Visual Studio.

To build the project

  1. Open the percentage/percentage.sln file with Visual Studio
  2. Click "Build > Build Solution"
  3. percentage.exe can be found at percentage\percentage\percentage\bin\Debug\percentage.exe

Contributions

My goal for this project is to keep it as simple as possible. I welcome suggestions, but for complicated features I'd recommend forking the project.

percentage's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

percentage's Issues

请把电量数字加粗

现在的电量数字字体小且细,不容易分辨,请使用和时间数字一样的字体,谢谢!
Now the power digital font is small and thin, not easy to distinguish, please use the same font as the time number, thank you!

Display quality and background color

The number is a little blurry, and the background colour is black while my taskbar isn't so it's contrasting. Can it have the same background colour as my taskbar?

Discrepancy between windows and percentage

So it appears that percentage doesn't match what Windows is reporting at times.

For example, currently, Windows is reporting 98% charged when I hover over the battery icon, but Percentage is reporting 97%. I know it's not much there but it does make me wonder about lower levels.

I will update this issue as I check at different levels throughout the week.

System

MacBook Pro Retina (Mid 2014)
Windows 10 Pro running in Bootcamp

Digits looks blurry

I have been searching for such a program for a long time, thank you for your work. The only thing I would like to correct is the blurry digits. Perhaps it is worth to increase the font thickness or its sharpness to bring it closer to other fonts in the task bar. Probably can't be said that they are completely blurred, but they don't look exactly as they would like.

Blink red on low battery

Can the background of the battery light indicator turn red, or blink red?
Ex. At 15% the background turns red, and at 5% the background blinks red (on and off) until charging

Change color according to electricity

var powerLineStatus = powerStatus.PowerLineStatus;
batteryPercentage = (powerStatus.BatteryLifePercent * 100).ToString();
var bg_color = Color.Green;
if (int.Parse(batteryPercentage) < 60)
{
bg_color = Color.Orange;
}
if (int.Parse(batteryPercentage) < 30)
{
bg_color = Color.Red;
}
if (powerLineStatus== PowerLineStatus.Online)
{
bg_color = Color.Green;
}
using (Bitmap bitmap = new Bitmap(DrawText(batteryPercentage, new Font(iconFont, iconFontSize), Color.White, bg_color)))

% Icon

As the title describe, can you add it with the percent number?

Could not start.

See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at percentage.TrayIcon.timer_Tick(Object sender, EventArgs e)
at System.Windows.Forms.Timer.OnTick(EventArgs e)
at System.Windows.Forms.Timer.TimerNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

************** Loaded Assemblies **************
mscorlib
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3260.0 built by: NET472REL1LAST_C
CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll

百分比电池图标
Assembly Version: 1.0.0.0
Win32 Version: 1.3.0
CodeBase: file:///D:/Downloads/Compressed/%E7%99%BE%E5%88%86%E6%AF%94%E7%94%B5%E6%B1%A0%E5%9B%BE%E6%A0%87.exe

System.Windows.Forms
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3260.0 built by: NET472REL1LAST_C
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll

System
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3314.0 built by: NET472REL1LAST_B
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll

System.Drawing
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3190.0 built by: NET472REL1LAST_C
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll

System.Configuration
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3190.0 built by: NET472REL1LAST_C
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll

System.Core
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3260.0 built by: NET472REL1LAST_C
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll

System.Xml
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3190.0 built by: NET472REL1LAST_C
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll

Accessibility
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3190.0 built by: NET472REL1LAST_C
CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/Accessibility/v4.0_4.0.0.0__b03f5f7f11d50a3a/Accessibility.dll

************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.

For example:

When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.

Is this becuase I don't have the appropriate .net?

advices

1.Think completely and work and that thinking should be done at once,do like this when writing also ,as little thinking causes mistakes.

2.think of each bit of how it can be improved but don't add useless features

3.Increase patience

4.do important work first

5.If u can't reproduce a bug normally then test thoroughly and try to repro for 2,3 times.

6.As far as possible try to reproduce bugs in win10 64b as most of the users in the world use win10

Make this read by your developers or else mistakes will happen.If they completely think and work then bugs will be properly fixed

Option to display accurate battery remaining time, alternative to percentage

You can easily find a tool that displays battery level in percentage, but there is currently no app available that displays the remaining time in hours and minutes. One option is to use HWINFO, which only displays minutes.

However, there is one issue with this approach. Windows calculates the remaining time using an averaging method. This means that if you are performing intensive tasks for a period of time, the estimated remaining time will appear low. Conversely, if you stop doing these tasks, it will take some time for Windows to recalculate the remaining battery life. On the other hand, HWINFO provides immediate calculations. So if you are not doing anything intensive, you may see a high number of battery hours. However, if you start using an application like Photoshop, the remaining time will immediately drop and return to normal once the application is fully loaded.

In my opinion, there should be an option to adjust the aggressiveness of the battery calculation to provide a more accurate estimate.

I made some nice improvements and want to commit

Based on your project, I changed the font to a bitmap one, with digital digits, made the background transparent and added an animation when charging. Let me know if you want to include those changes
digital

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.