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

Feature Request: disable bell #2360

Closed
ffes opened this issue Aug 8, 2019 · 11 comments · Fixed by #7793
Closed

Feature Request: disable bell #2360

ffes opened this issue Aug 8, 2019 · 11 comments · Fixed by #7793
Assignees
Labels
Area-Settings Issues related to settings and customizability, for console or terminal Area-VT Virtual Terminal sequence support Issue-Task It's a feature request, but it doesn't really need a major design. Needs-Tag-Fix Doesn't match tag requirements Product-Terminal The new Windows Terminal. Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release.
Milestone

Comments

@ffes
Copy link

ffes commented Aug 8, 2019

Description of the new feature/enhancement

Make a setting to disable the bell. This could be a per profile setting.

Maybe other "bell" settings can be desirable like:

"bell": "enable"  (default)
"bell": "disable" (this feature request)
"bell": "visual"

So with that in mind don't let the setting be a boolean.

Probably related to #72

@ffes ffes added the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Aug 8, 2019
@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Aug 8, 2019
@DHowett-MSFT DHowett-MSFT added Area-Settings Issues related to settings and customizability, for console or terminal Area-VT Virtual Terminal sequence support Issue-Task It's a feature request, but it doesn't really need a major design. Product-Terminal The new Windows Terminal. and removed Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels Aug 8, 2019
@ghost ghost removed the Needs-Tag-Fix Doesn't match tag requirements label Aug 8, 2019
@DHowett-MSFT DHowett-MSFT added this to the Terminal v1.0 milestone Aug 8, 2019
@DHowett-MSFT
Copy link
Contributor

This depends on #1608.

@trajano
Copy link

trajano commented Aug 9, 2019

In addition, I want that to be configurable on both global and on profile level

One change though, instead of the following to be default

"bell": "enable" 

use

"bell": "default" 

that way we can use

"bell": "path to mp3,wav,ogg" 

@DHowett
Copy link
Member

DHowett commented Jun 22, 2020

I'm gonna merge this with "the terminal should actually support bell", because right now it actually doesn't even support bells.

/dup #4046

@ghost
Copy link

ghost commented Jun 22, 2020

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

@ghost ghost closed this as completed Jun 22, 2020
@ghost ghost added the Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. label Jun 22, 2020
@zadjii-msft
Copy link
Member

Hey with #7679 adding support for audible bells, let's re-open this to track disabling them (again)

@zadjii-msft zadjii-msft reopened this Sep 29, 2020
@zadjii-msft zadjii-msft removed the Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. label Sep 29, 2020
@ffes
Copy link
Author

ffes commented Sep 29, 2020

Since this issue is reopened, will this get the same milestone as #7679?

@zadjii-msft
Copy link
Member

zadjii-msft commented Sep 29, 2020

@ffes Absolutely, I'll make sure of that ☺️

Note to self: we should do this as an enum like:

"bellStyle": "audible"|"visible"|"none"

We don't need to implement visible right now, but we should do it this way so we're future-proof

DHowett pushed a commit that referenced this issue Oct 1, 2020
This commit makes the Windows Terminal play an audible sound when the
`BEL` control character is output.

The `BEL` control was already being forwarded through conpty, so it was
just a matter of hooking up the `WarningBell` dispatch method to
actually play a sound. I've used the `PlaySound` API to output the sound
configured for the "Critical Stop" system event (aka _SystemHand_),
since that is the sound used in conhost.

## Validation

I've manually confirmed that the terminal produces the expected sound
when executing `echo ^G` in a cmd shell, or `printf "\a"` in a WSL bash
shell.

References:
* There is a separate issue (#1608) to deal with configuring the `BEL`
  to trigger visual forms of notification.
* There is also an issue (#2360) requesting an option to disable the
  `BEL`.

Closes #4046
@zadjii-msft zadjii-msft self-assigned this Oct 1, 2020
@ghost ghost added the In-PR This issue has a related PR label Oct 1, 2020
@ghost ghost added Needs-Tag-Fix Doesn't match tag requirements Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release. and removed In-PR This issue has a related PR labels Oct 15, 2020
DHowett pushed a commit that referenced this issue Oct 15, 2020
Adds a new setting, `bellStyle`, to be able to disable the audible bell
added in #7679. Currently, this setting accepts two values:
* `audible`: play a noise on a bell
* `none`: Don't play a noise.

In the future, we can add a `"bellStyle": "visible"` for flashing the
Terminal instead of making a noise on bell.

## Validation Steps Performed
Pressing <kbd>Ctrl+G</kbd> in cmd, and hitting enter is an easy way of
triggering a bell. I set the setting to `none`, and presto, the bell
stopped.

Closes #2360
@ghost
Copy link

ghost commented Nov 11, 2020

🎉This issue was addressed in #7793, which has now been successfully released as Windows Terminal Preview v1.5.3142.0.:tada:

Handy links:

@nathanblair
Copy link

I'm on the Windows Terminal Preview from the Microsoft Store, and while I can't determine if the bell is truly disabled for a Powershell shell, I am definitely hearing it while in Alpine WSL.

Here's what I have in my settings.json (which I allowed Terminal to recreate after installing the newest 1.5 release):

    ...
    "bellStyle": "none",
    ...

I'll note that VS Code was unable to see any "bell" properties (I assume these properties are populated from the json schema).

I have other features from 1.5 like a maximizedFocus so I'm positive I have the most recent version. Should I do a full uninstall and then install Terminal Preview fresh?

@zadjii-msft
Copy link
Member

Where did you put bellStyle? In the global settings (at the root of the json), or in a profile? Since bellStyle is a per-profile setting, if you want it to apply to all profiles, you'll need to put it in the profiles.defaults object:

image

@nathanblair
Copy link

Excellent call! Indeed, that fixes it. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Settings Issues related to settings and customizability, for console or terminal Area-VT Virtual Terminal sequence support Issue-Task It's a feature request, but it doesn't really need a major design. Needs-Tag-Fix Doesn't match tag requirements Product-Terminal The new Windows Terminal. Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants