Skip to content

Conversation

@cryonox
Copy link

@cryonox cryonox commented Aug 31, 2025

Checks

Feature description

This implements list of changes so that "Talking UI" can act more like an actual overlay. The changes are:

  • Settings/UI changes to able to set short cut key to "trigger transparency"
  • UI changes to settings for Transparency Level setting
  • When transparency short cut key is triggered it intends to do the following. However currently, not everything is working as intended and only windows has full intention working.
    • Remove windows decorations (title bar and close button) (cross platform working)
    • Set transparency to the value set in settings UI (cross platform working)
    • Set the UI transparent to mouse events (clickthrough) (only working on windows). The code as it stands on other platforms will be able to click while in transparent mode.
    • If background color is set in settings UI, only the content will be set to background. This aims to achieve a minimal look to reduce visual clutter (cross platform working).

See this video on how it should look. https://www.youtube.com/watch?v=FyiMCaXfKvg

Copy link
Member

@Hartmnt Hartmnt left a comment

Choose a reason for hiding this comment

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

You have tested this only on Windows so far, correct?

LOAD(iTalkingUI_PrefixCharCount, "ui/talkingUI_PrefixCharCount");
LOAD(iTalkingUI_PostfixCharCount, "ui/talkingUI_PostfixCharCount");
LOAD(qsTalkingUI_AbbreviationReplacement, "ui/talkingUI_AbbreviationReplacement");
LOAD(iTalkingUI_TransparencyLevel, "ui/talkingUI_TransparencyLevel");
Copy link
Member

Choose a reason for hiding this comment

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

Can be removed. This method loads legacy settings. Since you are creating a new setting, there will be no one with that setting trying to migrate.

</property>

<property name="toolTip">
<string>Transparency level of the TalkingUI. </string>
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
<string>Transparency level of the TalkingUI. </string>
<string>Transparency level of the TalkingUI.</string>

Comment on lines +636 to +638
<property name="accessibleName">
<string>Transparency level</string>
</property>
Copy link
Member

Choose a reason for hiding this comment

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

This is a bad accessibleName. This field is used for users with assistive technology such as screen readers. When they tab into this new field they will simply hear "transparency level" and there is no context that this affects the talking UI.

I'd change this and the toolTip to "TalkingUI background transparency level" or something similar

int iTalkingUI_PostfixCharCount = 2;
QString qsTalkingUI_AbbreviationReplacement = QStringLiteral("...");
std::optional< QColor > talkingUI_BackgroundColor = std::nullopt;
int iTalkingUI_TransparencyLevel = 255;
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
int iTalkingUI_TransparencyLevel = 255;
int talkingUI_TransparencyLevel = 255;

We dropped type hints in variable names for new code

Comment on lines +442 to +446
void LookConfig::on_qsbTransparencyLevel_valueChanged(int value) {
// Handle transparency level change
Q_UNUSED(value);
// You can add preview logic here if needed
}
Copy link
Member

Choose a reason for hiding this comment

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

This seems superfluous 👀

Comment on lines +437 to +440
void LookConfig::on_qcbTalkingUITransparent_stateChanged(int state) {
// Handle transparency checkbox state change
qsbTransparencyLevel->setEnabled(state == Qt::Checked);
}
Copy link
Member

Choose a reason for hiding this comment

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

In new code, we want to move away from implicit event connections by method name like this.

Please refactor this to use a plausible name like toggleTransparency or something and use the QObject::connect() method to explicitly connect the event.
Should look something like
QObject::connect(qcbTalkingUITransparent, QComboBox::stateChanged, this, LookConfig::toggleTransparency) (untested)

@Hartmnt Hartmnt added client feature-request This issue or PR deals with a new feature labels Sep 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

client feature-request This issue or PR deals with a new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants