This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 222562 - CTRL-F is disabled after running for a while (Not limited to remote desktop)
Summary: CTRL-F is disabled after running for a while (Not limited to remote desktop)
Status: REOPENED
Alias: None
Product: editor
Classification: Unclassified
Component: Actions/Menu/Toolbar (show other bugs)
Version: 8.2
Hardware: PC Windows 10 x64
: P2 normal with 7 votes (vote)
Assignee: Miloslav Metelka
URL:
Keywords:
: 232342 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-11-21 19:23 UTC by gmtschlr
Modified: 2019-07-10 07:39 UTC (History)
9 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
IDE log (453.32 KB, text/plain)
2012-11-21 19:23 UTC, gmtschlr
Details
Log of remote and local activity (79.31 KB, application/octet-stream)
2012-12-18 19:12 UTC, gmtschlr
Details

Note You need to log in before you can comment on or make changes to this bug.
Description gmtschlr 2012-11-21 19:23:31 UTC
Product Version = NetBeans IDE 7.3 Beta 2 (Build 201211062253)
Operating System = Windows 7 version 6.1 running on amd64
Java; VM; Vendor = 1.7.0_03
Runtime = Java HotSpot(TM) 64-Bit Server VM 22.1-b02

Submitted this issue before (222232) and it was closed as incomplete.  I was instructed to reopen the report after running withmore informative  logging (netbeans -J-Dorg.openide.awt.GeneralAction.level=500)

I did this, and netbeans proved very obliging by failing promptly.

That is, I started netbeans from home via remote desktop, using the above command line.  Did some work, minimized it and then came into the office and brought it back, whereupon  CTRL-F failed with a BEL and no search dialog box.

I have checked the "attach log file" box, which I presume includes the log you are looking for.
Comment 1 gmtschlr 2012-11-21 19:23:33 UTC
Created attachment 128227 [details]
IDE log
Comment 2 Milutin Kristofic 2012-11-22 13:49:22 UTC
Thank you very much for this report.

I am moving to Jarda, he knows better why action cannot be found.
Comment 3 Jaroslav Tulach 2012-11-22 14:25:56 UTC
I don't know anything. Especially about editor. I am sorry, I can't solve this issue without help from editor. Here are few questions:

When you say "action is not found" what do you mean? This part of the log file?

FINE [org.openide.awt.GeneralAction]: Action for key: cut-to-clipboard is: org.netbeans.modules.java.editor.imports.ClipboardHandler$JavaCutAction@3f6b294a
FINE [org.openide.awt.GeneralAction]: Action for key: copy-to-clipboard is: org.netbeans.editor.BaseKit$CopyAction@39001cd8
FINE [org.openide.awt.GeneralAction]: Action for key: org.openide.actions.FindAction is: null

Do you think the output should be different? Is the find action registered in the same map as copy-to-clipboard? Is there any way to verify it is still there even the "Action for key: org.openide.actions.FindAction is: null"?
Comment 4 Milutin Kristofic 2012-11-26 17:40:04 UTC
We need to find a source of problems. I added logs to dev build. http://hg.netbeans.org/jet-main/rev/cebc952d0f2e

It should be in tomorrow's or 2-days build in http://bits.netbeans.org/download/trunk/nightly/latest/

Netbeans should be run with 
netbeans -J-Dorg.netbeans.modules.editor.NbEditorKit.level=500

The output when find is working is
FINE [org.netbeans.modules.editor.NbEditorKit]: Declared Actions (found (123)): 
...
FINE [org.netbeans.modules.editor.NbEditorKit]: Action: SearchAction@1404110084 mime="null" name="find"
...

This will be very helpful. Thank you.
Comment 5 Quality Engineering 2012-11-27 02:57:51 UTC
Integrated into 'main-golden', will be available in build *201211270002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/cebc952d0f2e
User: Milutin Kristofic <mkristofic@netbeans.org>
Log: #222562 - CTRL-F is disabled after running for a while (via remote desktop)
Comment 6 Milutin Kristofic 2012-11-28 12:40:05 UTC
*** Bug 202740 has been marked as a duplicate of this bug. ***
Comment 7 gmtschlr 2012-12-14 19:51:07 UTC
Sorry, lost remote access when we moved offices and only just got it back.

Downloaded daily version (2012 12 13) and will try this on Monday.
Comment 8 gmtschlr 2012-12-18 19:12:40 UTC
Created attachment 129517 [details]
Log of remote and local activity

Log taken by running remotely, performing some searches, and then coming into the office and trying another search, which fails.
Comment 9 Milutin Kristofic 2013-07-22 13:20:18 UTC
*** Bug 232342 has been marked as a duplicate of this bug. ***
Comment 10 Martin Balin 2015-09-17 11:00:13 UTC
Report from old NetBeans version. Due to code changes since it was reported likely to not happen. Feel free to reopen if happens in 8.0.2 or 8.1.
Comment 11 SandritaD 2016-11-17 15:08:09 UTC
I encountred the same Problem with netbeans 8.1
Comment 12 alex1982 2016-11-29 16:11:06 UTC
I can confirm this issue on my working machine:
Product Version: NetBeans IDE 8.1 (Build 201510222201)
Java: 1.8.0_102; Java HotSpot(TM) 64-Bit Server VM 25.102-b14
Runtime: Java(TM) SE Runtime Environment 1.8.0_102-b14
System: Windows 10 version 10.0 running on amd64; Cp1252; de_DE (nb)


As I recovered the behaviour right now, the search field menu bar under the code window does not open when pressing CTRL + F under the following circumstance:

1. Opening Netbeans, working with it
2. leave the PC for lunch break by pressing WIN + L to lock my operating system
3. returning after roundabout 30 minutes or more to the pc (screen saver is running) and logging myself on into Windows by typing in my password
4. focus on the Netbeans window and pressing CTRL + F

Expectation:
Search bar opens under the code window with the cursor set to the search field (normal behaviour like a new start of the IDE)

Result:
As I remember it correctly right now the focus jumps to the Navigator window and no search bar or search field appears.
I will update my description if I get this problem again.

Until now it happened at least 10 times to me with almost the same process.
Comment 13 alex1982 2016-12-06 13:39:08 UTC
Now with Netbeans 8.2 and the same system as mentioned in my comment before the behaviour is almost the same. After returning to the system and pressing CTRL + F, no search bar (field) appeared at the focused file. Changing to another file made the search bar appear, but not on every file. I have roundabout 10 files opened, .html and .scss files, in some files I am able to search and in others not. 

When I scrolled, an silent error appeared: http://statistics.netbeans.org/analytics/exception.do?id=838400 (my description there is missing the scroll I made .... :( )
Comment 14 atlioddsson 2016-12-14 16:32:38 UTC
I'm still having this problem with the Netbeans 8.2 unfortunately. I can see I reported on this in 2012 as well, exact same problem.

Product Version: NetBeans IDE 8.2 (Build 201609300101)
Java: 1.8.0_92; Java HotSpot(TM) 64-Bit Server VM 25.92-b14
Runtime: Java(TM) SE Runtime Environment 1.8.0_92-b14
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)


Note, as mentioned before, this is correlated with Remote Desktop (netbeans is running on the remote computer). Restarting Netbeans fixes the problem (but re-appears if I log back in using RDC).
Comment 15 atlioddsson 2016-12-14 16:43:12 UTC
Just noticed as well that I can close the file in the NB editor and reopen it (not enough to Ctrl-Tab back and forth) and then the Find functionality can be activated as normally.

This makes it slightly better since I don't have to restart Netbeans (and possibly tomcat instances etc).
Comment 16 hickja 2017-02-27 01:50:17 UTC
I can confirm I am also impacted by this bug - it's extremely annoying! It seems to have been around in some forms since 2012 - and agree it correlates with RDP sessions to the machine; are there any thoughts as to potential long term fixes?
Comment 17 hsbgowd 2017-03-09 01:03:29 UTC
I have this problem with Netbeans v 8.2. I have some new info that might help you debug/fix.

11 files were open when this issue happened. (I will refer to them as older files in below description)

Ctrl-F and even Edit->Find and Edit->Replace options were disabled. On new files that I opened at this time, the Ctrl-F, Edit->Find and Edit->Replace were enabled.
While switching between the newer files that I opened, these options were available, but these options were not available when I switched to the older files. After closing and reopening all the older files, issue was resolved.

Hope this hepls!
Comment 18 hsbgowd 2017-03-09 01:17:12 UTC
Update to my previous comment.
Using the "Clone" option on the files which had this issue, helped me get back the Ctrl-F, Edit->Find and Edit->Replace option on the cloned file.

Also, the "Projects" window lost its scroll bar and I couldn't get it back even after closing and reopening just the Projects window. I think this issue might be related.
Comment 19 reijkie 2017-03-16 12:41:02 UTC
Same problem here with Netbeans 8.1. No idea what causes it, but comment 12 comes closest.
Comment 20 bwolther 2017-03-27 18:40:54 UTC
I am able to reliably reproduce this problem. It occurs whenever I disconnect a Microsoft Remote Desktop session (to a Windows 7 host on which NB is running) and reconnect it with the "Font smoothing" option disabled on the "Experience" tab of the Remote Desktop options. In other words, if Font smoothing is enabled, I don't have the problem. If Font smoothing is disabled, then the Find... option gets greyed out (disabled).

Product Version: NetBeans IDE 8.2 (Build 201609300101)
Updates: NetBeans IDE is updated to version NetBeans 8.2 Patch 1
Java: 1.8.0_101; Java HotSpot(TM) 64-Bit Server VM 25.101-b13
Runtime: Java(TM) SE Runtime Environment 1.8.0_101-b13
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
User directory: C:\Users\XXXX\AppData\Roaming\NetBeans\8.2
Cache directory: C:\Users\XXXX\AppData\Local\NetBeans\Cache\8.2
Comment 21 Miloslav Metelka 2017-04-03 13:25:23 UTC
(In reply to bwolther from comment #20)
I've recently fixed issue #257185 (fix available in build *201703310002*). Could you please test your setup on that (or later) dev build? Thanks.
Comment 22 bwolther 2017-04-03 15:05:59 UTC
(In reply to Miloslav Metelka from comment #21)
> (In reply to bwolther from comment #20)
> I've recently fixed issue #257185 (fix available in build *201703310002*).
> Could you please test your setup on that (or later) dev build? Thanks.

This bug persists after your change. I re-tested with "Product Version: NetBeans IDE Dev (Build 201704030002)". I was able to reproduce bug (and workaround) with same method as I described in comment #20 above.
Comment 23 Quality Engineering 2017-04-06 02:52:12 UTC
Integrated into 'main-silver', will be available in build *201704060002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/6bce483b529d
User: Miloslav Metelka <mmetelka@netbeans.org>
Log: #222562 - CTRL-F is disabled after running for a while (via remote desktop) - added logging of UI property changes.
Comment 24 Miloslav Metelka 2017-04-06 12:24:45 UTC
Could you please download build *201704060002* or later and run the IDE with 

-J-Dorg.netbeans.editor.BaseTextUI.level=FINE

(possibly see http://wiki.netbeans.org/FaqNetbeansConf )

and check if there will be a following message from the logger either on NB console or in the log file?

UI property changed for text component ...
OldUI: javax.swing.plaf.synth.SynthEditorPaneUI@68cb1671
NewUI: org.netbeans.editor.BaseTextUI@6029d52c

Thanks.
Comment 25 Miloslav Metelka 2017-04-06 12:40:32 UTC
I mean whether there will be a UI property change once the problem with Ctrl+F occurs? Or possibly attach the few lines dumped by the logger. Thanks.
Comment 26 bwolther 2017-04-07 19:28:49 UTC
(In reply to Miloslav Metelka from comment #25)
> I mean whether there will be a UI property change once the problem with
> Ctrl+F occurs? Or possibly attach the few lines dumped by the logger. Thanks.

I tested with NetBeans IDE Dev (Build 201704070002).

I pasted a snippet of messages.log below. I inserted some of my own comments, denoted by lines beginning with "==BW==".

I observed for the first time that, even with font-smoothing enabled in Remote Desktop, CTRL-F will be disabled the first time I reconnect after a new session of NB has been started. But that only occurs in the first RD connection of the NB session. Subsequent re-connections consistently cause the CTRL-F problem only when font-smoothing is disabled.



.../var/log/messages.log ...

INFO [org.netbeans.modules.parsing.impl.indexing.RepositoryUpdater]: Indexing of: C:\Program Files\NetBeans Dev 201704070002\webcommon\jsstubs\corestubs.zip took: 62 ms (New or modified files: 0, Deleted files: 0) [Adding listeners took: 0 ms]
INFO [org.netbeans.modules.parsing.impl.indexing.RepositoryUpdater]: Complete indexing of 3 source roots took: 1,606 ms (New or modified files: 0, Deleted files: 0) [Adding listeners took: 0 ms]
WARNING [org.netbeans.modules.progress.spi.InternalHandle]: Cannot switch to silent mode when not running at org.netbeans.core.ui.warmup.MenuWarmUpTask$NbWindowsAdapter$1HandleBridge.run(MenuWarmUpTask.java:269)
WARNING [null]: Last record repeated 4 more times.

==BW== before first RD disconnect

==BW== after first RD reconnect1 with Font-smoothing enabled in Remote Desktop

WARNING [org.openide.util.WeakListenerImpl]: Can't remove java.beans.PropertyChangeListener using method org.netbeans.modules.csl.core.GsfDocument.removePropertyChangeListener from org.netbeans.modules.csl.core.GsfDocument@708c07b, mimeType='text/javascript', kitClass=null, length=8287, version=1, 

==BW== Observation CTRL-F is disabled

==BW== Clone tab to restore a working CTRL-F

file=org.netbeans.modules.csl.core.GsfDataObject@1bfed954[H:\dev\js\j360_1.js@e9cb1551:13f8a3ac]
INFO [org.netbeans.core.windows.persistence]: [PersistenceManager.getTopComponentForID] Problem when deserializing TopComponent for tcID:'CoverageReportTopComponent'. Reason: Top component CoverageReportTopComponent could not be located or loaded from Components folder.

==BW== Observation CTRL-F is enabled

==BW== before second RD disconnect

==BW== after second RD reconnect 2 with font-smoothing enabled in Remote Desktop

==BW== Observation CTRL-F is enabled

==BW== before third RD disconnect

==BW== after third RD reconnect with font-smoothing disabled in Remote Desktop

WARNING [org.openide.util.WeakListenerImpl]: Can't remove java.beans.PropertyChangeListener using method org.netbeans.modules.csl.core.GsfDocument.removePropertyChangeListener from org.netbeans.modules.csl.core.GsfDocument@708c07b, mimeType='text/javascript', kitClass=null, length=8287, version=1, file=org.netbeans.modules.csl.core.GsfDataObject@1bfed954[H:\dev\js\j360_1.js@e9cb1551:13f8a3ac]

==BW== Observation CTRL-F is disabled
Comment 27 pborregg 2017-07-24 06:39:49 UTC
This JUST happened to me. Everything, as NORMAL since I've been using NETBEANS 7.3

Now, I get an UPDATE request, today, and another, then another and the MENU FIND, REPLACE are DISABLED and the CTRL+F and CTRL+H REFUSE TO WORK.

I can, however, use FIND IN PROJECTS but that's the behaviour I WANT!

I WANT WHAT I HAVE HAD FOR YEARS: CTRL+F/+H

Someone has to have a SOLUTION that's VIABLE and WORKS. PERIOD!

Thank you for your assistance,

Peter
Comment 28 beany 2017-07-24 07:44:53 UTC
Hapens here. Product Version: NetBeans IDE 8.2 (Build 201705191307)
Happened the first time today after launching recent updates for this version.
Comment 29 dtoman 2017-11-23 07:33:20 UTC
Hi,

the problem occured to me too. Find and Replace disabled in Edit menu, CtrlF not working. I have about 10 files open and most of them have the Find inaccessible. All these have lost line numbering too. There are some file tabs which have line numbers and they do have Find working (and enabled in Edit menu). If I open a new file find works for it.

I don't know exactly when the CtrlF stopped working. Since I don't switch the PC off the IDE is running several days (since install) continuously. I tried to make remote xdebug working (with success - but there should be Path mapping mentioned somewhere where google will find it easily). Now as the first in the morning I switched to the Netbeans IDE and tried to find a function in a source code and I found out the 'Find action' is not working suddenly.

I installed netbeans before a few days for the first time:
NetBeans IDE 8.2 (Build 201609300101), runs on Windows7


I tried to find a reason why one could want to disable the Find in edit menu. I don't thing there is a file type fot which Find is a non-sense. 

Is really that hard to find all lines in code which disables/enables lines in edit menu and check if there is a possible problem with them?
Comment 30 Klynch 2017-12-21 14:08:39 UTC
I also am able to regularly produce this bug.  I believe it occurs when I leave netbeans running and enter sleep mode and bring back up the computer.    It is based on the individual files.  If I try to use ctrl-f on a file that had been left up, this bug occurs.  If I open a new file, ctrl-f works fine.  It may also be useful to note line numbers disappear as well for the files that are broken.  Once I close the file and reopen, it no longer has any problems.  

Notes on environment:
Product Version: NetBeans IDE 8.2 (Build 201609300101)
Updates: NetBeans IDE is updated to version NetBeans 8.2 Patch 2
Java: 1.8.0_112; Java HotSpot(TM) 64-Bit Server VM 25.112-b15
Runtime: Java(TM) SE Runtime Environment 1.8.0_112-b15
System: Windows 10 version 10.0 running on amd64; Cp1252; en_US (nb)
Comment 31 endl 2019-04-01 10:03:44 UTC
Fix this sht! I have this issue for about last 3 years starting from 8.1 or so. Update to the last version did not help. Now I use netbeans 10 and the issue does exist!!! It's annoying.
Comment 32 ankei 2019-07-10 07:39:08 UTC
Now you can attach here lots of things which are related for the http://freerobuxgenerator.net how to get free robux. Thanks a lot