Re: How to get Laptop battery level

2021-02-22 Thread H. S. Teoh via Digitalmars-d-learn
On Mon, Feb 22, 2021 at 08:59:01PM +, Greatsam4sure via Digitalmars-d-learn wrote: > Dlang is a system programming language. How do I access the battery > level of my system using code in dlang? I will appreciate vide sample There is no universal API for this. It depends on which OS you're u

Re: How to get Laptop battery level

2021-02-22 Thread Dukc via Digitalmars-d-learn
On Monday, 22 February 2021 at 21:14:48 UTC, Dukc wrote: Note that DGame seems to be currently unmaintained - it might have some bits that do not compile anymore. SDL2 is a commonly used library though - you should be able to find more examples about it if you need to. Plus, the example I lin

Re: How to get Laptop battery level

2021-02-22 Thread Dukc via Digitalmars-d-learn
On Monday, 22 February 2021 at 20:59:01 UTC, Greatsam4sure wrote: Dlang is a system programming language. How do I access the battery level of my system using code in dlang? As a systems language, D could access the hardware interface directly, if you knew it and loaded your program as a kerne

Re: How to get Laptop battery level

2021-02-22 Thread Greatsam4sure via Digitalmars-d-learn
On Monday, 22 February 2021 at 20:59:01 UTC, Greatsam4sure wrote: Dlang is a system programming language. How do I access the battery level of my system using code in dlang? I will appreciate code sample Sorry I mean to say code sample

How to get Laptop battery level

2021-02-22 Thread Greatsam4sure via Digitalmars-d-learn
Dlang is a system programming language. How do I access the battery level of my system using code in dlang? I will appreciate vide sample