Skip to content

Commit

Permalink
add tooltip on hover on welcomepage for jasp-stats/INTERNAL-jasp#2577
Browse files Browse the repository at this point in the history
  • Loading branch information
JorisGoosen committed Jun 19, 2024
1 parent ef363d9 commit 397b72a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
14 changes: 9 additions & 5 deletions Desktop/components/JASP/Widgets/WelcomePage.qml
Original file line number Diff line number Diff line change
Expand Up @@ -438,13 +438,14 @@ FocusScope
bottomMargin: 4 * welcomeRoot.scaler
}

MouseArea
JASPMouseAreaToolTipped
{
id: bugsMouseArea
hoverEnabled: true
onClicked: Qt.openUrlExternally(mainWindow.contactUrlBugs);
anchors.fill: parent
cursorShape: Qt.PointingHandCursor
toolTipText: mainWindow.contactUrlBugs
}
}

Expand All @@ -469,13 +470,14 @@ FocusScope
margins: 10 * welcomeRoot.scaler
}

MouseArea
JASPMouseAreaToolTipped
{
id: featureMouseArea
hoverEnabled: true
onClicked: Qt.openUrlExternally(mainWindow.contactUrlFeatures);
anchors.fill: parent
cursorShape: Qt.PointingHandCursor
toolTipText: mainWindow.contactUrlFeatures
}
}

Expand All @@ -500,13 +502,14 @@ FocusScope
bottomMargin: 4 * welcomeRoot.scaler
}

MouseArea
JASPMouseAreaToolTipped
{
id: jaspQuestionsMouseArea
hoverEnabled: true
onClicked: Qt.openUrlExternally("https://forum.cogsci.nl/index.php?p=/categories/jasp-bayesfactor");
onClicked: Qt.openUrlExternally(mainWindow.questionsUrl);
anchors.fill: parent
cursorShape: Qt.PointingHandCursor
toolTipText: mainWindow.questionsUrl
}
}

Expand All @@ -530,13 +533,14 @@ FocusScope
margins: 10 * welcomeRoot.scaler
}

MouseArea
JASPMouseAreaToolTipped
{
id: jaspStatsMouseArea
hoverEnabled: true
onClicked: Qt.openUrlExternally("https://www.jasp-stats.org");
anchors.fill: parent
cursorShape: Qt.PointingHandCursor
toolTipText: "https://www.jasp-stats.org"
}
}

Expand Down
3 changes: 2 additions & 1 deletion Desktop/mainwindow.h
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ class MainWindow : public QObject
Q_PROPERTY(QString contactUrlFeatures READ contactUrlFeatures CONSTANT )
Q_PROPERTY(QString contactUrlBugs READ contactUrlBugs CONSTANT )
Q_PROPERTY(QString contactText READ contactText NOTIFY contactTextChanged )

Q_PROPERTY(QString questionsUrl READ questionsUrl CONSTANT )

friend class FileMenu;
public:
Expand Down Expand Up @@ -129,6 +129,7 @@ class MainWindow : public QObject
const QString contactUrlFeatures() const;
const QString contactUrlBugs() const;
const QString contactText() const;
const QString questionsUrl() const { return "https://forum.cogsci.nl/index.php?p=/categories/jasp-bayesfactor"; }

public slots:
void setImageBackgroundHandler(QString value);
Expand Down

0 comments on commit 397b72a

Please sign in to comment.