Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added offset option #153

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

manimatters
Copy link

Added support for offset option which can be used to display multiple timezones.

Date / Time Offset
o ± x = Changes the current time ± x given minutes.
Can be used to display multiple timezone information with full support of other Formatting options. Anytime the format encounters ‘o±x’ pattern, the succeeding format pattern works on the offset time.

For example, if your system is set for India Standard Time, and you want to also see the time for Central Standard Time (10h 30m = 630m behind IST), you can specify
"IST:" hh:nn:ss tt "CST:"o-630hh:nn:ss tt
anything after the ‘o-630’ will use the offset time to be displayed.

We can have multiple offsets to show more timezones. Note that we will need to calculate the offset from the last offset time.

We can get it to look like
image
using the format string:
"IST"\nhh:nn:ss tt\nddd, dd mmm yyyy\n\n"CST"\no-630hh:nn:ss tt\nddd, dd mmm yyyy\n

Added support for offset option which can be used to display multiple timezones
Changed type to long instead of double to avoid typecasting issues
@mycoffees
Copy link

mycoffees commented Oct 17, 2018

My domain computer time cannot be changed, but it is 3 minutes slow. This feature will be very useful to me. But I'm do not know how to compile, and hopefully there will be a compiled version, absolutely。

@manimatters
Copy link
Author

My domain computer time cannot be changed, but it is 3 minutes slow. This feature will be very useful to me. But I'm do not know how to compile, and hopefully there will be a compiled version, absolutely。

I have uploaded the built binary from my system.
https://drive.google.com/file/d/1tNuE5S5oV1mvYl0wbdPcodUQgQ8CHWmp/view?usp=sharing

@White-Tiger
Copy link
Owner

My domain computer time cannot be changed, but it is 3 minutes slow. [...]

Since you're unable to change your Computer's time, does that mean you're not having administrator rights? I kinda believe it might be useful to have some sort of "real time" display even if the Computer's time is wrong, so I'd like to know the reason behind your problem (especially if it's a Chinese thing)

@mycoffees
Copy link

我的域计算机时间无法更改,但速度慢了3分钟。[ ... ]

由于您无法更改计算机的时间,这是否意味着您没有管理员权限?我有点相信,即使计算机的时间错误,也可以进行某种“实时”显示,所以我想知道问题背后的原因_(特别是如果它是中国的东西)_

My computer is the company's desktop, which is limited by some permissions and policies, and is offline, and the computer's time is forced to synchronize with the server, so it should be the server time is three minutes slow. But it's odd that some of my colleagues' computer time is normal.

@mycoffees
Copy link

mycoffees commented Oct 18, 2018

我的域计算机时间无法更改,但速度慢了3分钟。这个功能对我来说非常有用。但我不知道如何编译,并希望绝对会有一个编译版本。

我已经从我的系统上传了构建的二进制文件.https://drive.google.com/file/d/1tNuE5S5oV1mvYl0wbdPcodUQgQ8CHWmp/view ? usp = sharing

Thank you for sharing the file, but I replaced the original file and it prompted (api error(1). error loading :t-clock64.dll). My version is 2.4.4.492. Can you help me pack your whole program? thank you!

@manimatters
Copy link
Author

我的域计算机时间无法更改,但速度慢了3分钟。这个功能对我来说非常有用。但我不知道如何编译,并希望绝对会有一个编译版本。

我已经从我的系统上传了构建的二进制文件.https://drive.google.com/file/d/1tNuE5S5oV1mvYl0wbdPcodUQgQ8CHWmp/view ? usp = sharing

Thank you for sharing the file, but I replaced the original file and it prompted (api error(1). error loading :t-clock64.dll). My version is 2.4.4.492. Can you help me pack your whole program? thank you!

I will give it a go when I can.

@manimatters
Copy link
Author

我的域计算机时间无法更改,但速度慢了3分钟。这个功能对我来说非常有用。但我不知道如何编译,并希望绝对会有一个编译版本。

我已经从我的系统上传了构建的二进制文件.https://drive.google.com/file/d/1tNuE5S5oV1mvYl0wbdPcodUQgQ8CHWmp/view ? usp = sharing

Thank you for sharing the file, but I replaced the original file and it prompted (api error(1). error loading :t-clock64.dll). My version is 2.4.4.492. Can you help me pack your whole program? thank you!

I will give it a go when I can.

Can you try this, should have everything you need
https://drive.google.com/open?id=13pabbqKLJwIwPgltksePj0l-Kr0VjeC3

1 similar comment
@manimatters
Copy link
Author

我的域计算机时间无法更改,但速度慢了3分钟。这个功能对我来说非常有用。但我不知道如何编译,并希望绝对会有一个编译版本。

我已经从我的系统上传了构建的二进制文件.https://drive.google.com/file/d/1tNuE5S5oV1mvYl0wbdPcodUQgQ8CHWmp/view ? usp = sharing

Thank you for sharing the file, but I replaced the original file and it prompted (api error(1). error loading :t-clock64.dll). My version is 2.4.4.492. Can you help me pack your whole program? thank you!

I will give it a go when I can.

Can you try this, should have everything you need
https://drive.google.com/open?id=13pabbqKLJwIwPgltksePj0l-Kr0VjeC3

@njwgh
Copy link

njwgh commented Apr 7, 2019

+1 for this. I am using this version to display two timezones, without the leading zero on the hour

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants