Code Monkey home page Code Monkey logo

Comments (5)

Martchus avatar Martchus commented on June 14, 2024

another distro

Which one exactly would be good to know? And I assume you're also referring to the mingw-w64 package provided by that distro?

Can you provide a small demo project to reproduce?

I assume you use the regular, dynamic version (mingw-w64-qt5-base package)?

BTW: If you want to add a patch to this: https://github.com/Martchus/PKGBUILDs#contributing-to-patches

from pkgbuilds.

jaytea avatar jaytea commented on June 14, 2024

Sorry for the delay, I had a very busy weekend away from the PC.

Which one exactly would be good to know? And I assume you're also referring to the mingw-w64 package provided by that distro?

I now use Ubuntu with MXE, which also uses mingw-w64.

Can you provide a small demo project to reproduce?

I threw together a simple test qt-app:
time_test.zip

I assume you use the regular, dynamic version (mingw-w64-qt5-base package)?

Yes, you assume correctly.

from pkgbuilds.

Martchus avatar Martchus commented on June 14, 2024

In my case this issue is different. At least when testing with Wine:
screenshot_20180507_221110

In the background is the correct value (native Linux build) and in the foreground the Windows version started with Wine. So the time and Date.getHours() are even correct, but in the timezone the daylight saving is also missing.

Hard to tell what's causing this. I can't find any patches in the MXE which would fix this. I also doubt my own patches introduce any bugs regarding this. Yes, there are many patches, but most of them are about finding dependencies and other build system issues.

And in my case it is also just a QML issue. QDateTime works correctly. Eg.:

cout << "Qt: " << QDateTime::currentDateTime().toString(Qt::RFC2822Date).toLocal8Bit().data() << endl;
cout << "daylight saving: " << QDateTime::currentDateTime().isDaylightTime() << endl;

prints:

Qt: 07 May 2018 22:39:53 +0200
daylight saving: 1

from pkgbuilds.

jaytea avatar jaytea commented on June 14, 2024

That is weird with only the toString() being off. Though QDateTime also worked fine for me. So yeah, it is only a QML issue.
Interesting enough though, I once tried to supply the date through an interface into QML as a QDateTime and even then it had the same problem. So I would suspect the error being in the javascript engine and the Date type.
I don't know if I have some time to dig deeper into this, but if I do I will let you know what I find.
Thanks for your help!

from pkgbuilds.

stale avatar stale commented on June 14, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from pkgbuilds.

Related Issues (20)

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.