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 80798 - Search and replace with intelligent casing
Summary: Search and replace with intelligent casing
Status: RESOLVED DUPLICATE of bug 80732
Alias: None
Product: editor
Classification: Unclassified
Component: Search (show other bugs)
Version: 5.x
Hardware: All All
: P3 blocker with 1 vote (vote)
Assignee: Martin Roskanin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-07-21 10:43 UTC by randahl
Modified: 2008-01-23 09:56 UTC (History)
2 users (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description randahl 2006-07-21 10:43:06 UTC
I am filing this issue after a long talk on the NetBeans user's list about
search and replace. It seems we are several user's who would very much like to
save some time when searching for and replacing string litterals. Here is an
example of when this is relevant.

Say we start out by calling four wheeled vehicles "automobiles" and then later
decide to call the "cars" instead. This may mean that we have classes lie
Automobile and Car aswell as identifiers like automobile and car. What we would
like to do is to replace the term "automobile" with the term "car" in a case
sensitive way, so that all of the following code would be renamed in a single
replace-all operation:

(before replace all:)
Automobile automobile;
Automobile otherAutomobile;
public void sellAutomobile(Automobile automobileToBeSold) {...}

(after replace all:)
Car car;
Car otherCar;
public void sellCar(Car carToBeSold) {...}

As you can see the search and replace is taking place both for "Automobile" and
"automobile". In the IDE version 5.0 you need two operations to do this, one for
each spelling of the word - this could all be done in a single operation and
speed up our work by a factor 2.

What I suggest is simply an extra check box in the search and replace dialog
which enables what you could call "automatic casing". Since this feature is
available in Emacs and Microsoft IDEs (as stated on the nbuser list by others)
you might want to check out what this is called elsewhere to avoid confusion.

I think this is a low hanging fruit: Not expensive to implement / high impact.

Randahl
Comment 1 Vitezslav Stejskal 2008-01-23 09:56:10 UTC

*** This issue has been marked as a duplicate of 80732 ***