Suggestion: Make Ctrl+F open AND close Find feature

Talk about code development, features, specific bugs, enhancements, patches, and similar things.
Forum rules
Please keep everything here strictly on-topic.
This board is meant for Pale Moon source code development related subjects only like code snippets, patches, specific bugs, git, the repositories, etc.

This is not for tech support! Please do not post tech support questions in the "Development" board!
Please make sure not to use this board for support questions. Please post issues with specific websites, extensions, etc. in the relevant boards for those topics.

Please keep things on-topic as this forum will be used for reference for Pale Moon development. Expect topics that aren't relevant as such to be moved or deleted.
User avatar
ron_1
Moon Magic practitioner
Moon Magic practitioner
Posts: 2852
Joined: 2012-06-28, 01:20

Suggestion: Make Ctrl+F open AND close Find feature

Unread post by ron_1 » 2015-03-05, 23:34

When using the Find feature, I access it by pressing Ctrl+F. To close it I usually click on the "X," but the other day, since my fingers were still on the keyboard, I tried to close it by pressing Ctrl+F again, thinking that would close it. To my mild surprise it did not close it. I assume the shortcut is coded this way, but it seems natural to me that pressing Ctrl+F a second time should close it. The full-screen shortcut, F11, works this way.

This isn't a big deal to me (but it would be nice), just thought I'd bring it up. If it were to take more than a minute to code this behavior, it certainly isn't worth it, as I know Moonchild is busy frying bigger fish.


Supernova

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by Supernova » 2015-03-06, 01:10

Suggested it as part of a previous findbar enhancements ideas.
The addon is good, but a better built-in findbar would be handy.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35474
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by Moonchild » 2015-03-06, 10:38

Which other application does this?
The normal key to close the find bar/find function in applications is "Esc" to cancel the current action.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

Supernova

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by Supernova » 2015-03-06, 17:00

LibreOffice does this.

User avatar
ron_1
Moon Magic practitioner
Moon Magic practitioner
Posts: 2852
Joined: 2012-06-28, 01:20

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by ron_1 » 2015-03-07, 03:19

Moonchild wrote:
The normal key to close the find bar/find function in applications is "Esc" to cancel the current action.
I never thought of trying "Esc." It still seems more logical to me to just press Ctrl+F a second time to close the find bar. But like I said, it's not that big of a deal to me.

jumba

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by jumba » 2015-03-08, 09:48

I think it could work when the find field has already focus. Now pressing it second time just selects all text, which can be done with ctrl+a.

User avatar
Ozzed
Fanatic
Fanatic
Posts: 197
Joined: 2014-05-08, 11:37
Location: Sweden
Contact:

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by Ozzed » 2015-04-09, 06:34

I agree that it would be logical that Ctrl+F would close it if it's allready open, since there's no other logical binding. ESC works but it's counter-intuitive if you're used to doing it the other way. I think both should work :)

New Tobin Paradigm

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by New Tobin Paradigm » 2015-04-09, 07:28

No because it would break user expectations of getting findbar focus back by hitting ctrl+f again.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35474
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by Moonchild » 2015-04-09, 07:52

In other words: there is a logical binding when the find bar is open: focus.

In addition, assuming that something is intuitive just because you are used to it is rather short-sighted. That only satisfies the "expectation" part, and only for those people who are used to this from specific other tools that do this (and not any established standard).
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

New Tobin Paradigm

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by New Tobin Paradigm » 2015-04-09, 08:15

In most other tools I have used I find ctrl+f causes a regain of focus to the find UI such as in Notepad++ as well as Good ol' Notepad, Wordpad, Skype, Trillian, and about every other Windows program that has a find function.

However, some programs that may be cross platform or have a *nix history seem function as the OP wants it to work.. But even in the world of linux some tools also do it like we and most windows programs do. I would therefor be confident that the current behavior is consistent with the defacto standard in this case.

But.. All is not lost.. If you want to make a small extension to change the behavior you are free to do so and it will be gladly listed on the Add-ons site OR if you want to make this behavior available via a pref in Pale Moon then patches are welcome.

SvenG

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by SvenG » 2015-04-09, 08:59

I guess there is no really logical behavior for this. Maybe it is possible to do a compromise (as an addon). If the find bar is in focus CTRL+F closes it else it takes focus. Having to hit CTRL+F twice to close the find bar when it is out of focus is still easier to move to another key (ESC), while CTRL+F is useless when the find bar already is in focus.

Supernova

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by Supernova » 2015-04-09, 09:20

This looks like a good compromise.
Btw, tested on LibreOffice and that is what is done : if out of focus, take focus, if focused already, close the findbar.

User avatar
1210_bex
Lunatic
Lunatic
Posts: 354
Joined: 2013-10-09, 04:09
Location: USA

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by 1210_bex » 2015-05-16, 03:14

SvenG wrote:Try
https://addons.palemoon.org/extensions/ ... bar-tweak/
does what you want and a few more things.
I am having a problem with the Find feature in Pale Moon (now 25.4.1) & Firefox (now 37), which FinderBar Tweak does not address.

My issue pertains to the background color of the FIND bar (CTRL+F) for finding items. For most websites and similar items, CTRL-F creates a black background with white text. See item #1 on the attachment. Everything is easy to see and read. (I have collapsed both #1 & #2 items vertically so easier to see the Find bar.)

But when I try to use CTRL-F to view the page source of a webpage, The background becomes white, and the text black. Unfortunately the page source also has a white background, so that makes almost everything in the Find bar line unreadable. See #2 on the attachment.

Has anyone run into this problem, and if so is there a solution? Or is there some way that I can change the colors so in #2 they are reversed--white text on a black background?

Harry
Attachments
Ctrl_F_problem.gif

squarefractal

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by squarefractal » 2015-05-16, 16:24

Are you using a custom theme? Try disabling that, if you have one.

User avatar
1210_bex
Lunatic
Lunatic
Posts: 354
Joined: 2013-10-09, 04:09
Location: USA

Re: Suggestion: Make Ctrl+F open AND close Find feature

Unread post by 1210_bex » 2015-05-16, 17:30

squarefractal:

Yes I am. But I went back and tried the default, and it made no difference.

Harry

Locked