Skip to content

Added missing QWidget set methods and QCursor support#76

Merged
a7ul merged 2 commits intonodegui:masterfrom
Uriziel01:feature/missingQWidgetSetMethodsAndQCursor
Aug 31, 2019
Merged

Added missing QWidget set methods and QCursor support#76
a7ul merged 2 commits intonodegui:masterfrom
Uriziel01:feature/missingQWidgetSetMethodsAndQCursor

Conversation

@Uriziel01
Copy link
Copy Markdown
Contributor

Added few set methods to QWidget, QCursor definition. It will be much more useful in future, now you can use it to get and set current user pointer position.

Changed few things in demo to make it more appealing to the user (and fixed issue where window was sometimes opened under active window on Windows platform by forcing win.setWindowState(WindowState.WindowActive);)

@Uriziel01 Uriziel01 force-pushed the feature/missingQWidgetSetMethodsAndQCursor branch from 789c2c9 to 5447b6c Compare August 31, 2019 16:49
import { Component, NativeElement } from "../../core/Component";
import { QPixmap } from "../QPixmap";

type arg = NativeElement | number | QPixmap;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be just number
We could remove both NativeElement and QPixmap from here

Copy link
Copy Markdown
Contributor Author

@Uriziel01 Uriziel01 Aug 31, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This actually was left intentionally because I intend to add full support for QBitmap /QPixmap/QMasks/QCursor instances cursors, just did not have time on hand right now.
Do you think this should be removed from this PR?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No its okay. Let it be.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will merge this PR then ? @Uriziel01

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@@ -22,6 +23,7 @@ const win = new QMainWindow();
const label = new QLabel();
label.setText("Hello world 🧙");
label.setInlineStyle("font-size: 20px;");
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@a7ul
Copy link
Copy Markdown
Collaborator

a7ul commented Aug 31, 2019

I was just about to release a new version. I think this deserves to be in there as well 😃

@a7ul a7ul merged commit 3c51b99 into nodegui:master Aug 31, 2019
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.

2 participants