Other First refactoring feature!

Erel

Administrator
Staff member
Licensed User
The next version of B4J (and all other B4X tools) will include the very first refactoring feature: Rename To.

It makes it simple to rename global and local variables, subs and type fields.
It works as an extension to the useful Find All References tool. First you find the references and then you can rename the identifier name:

rename.gif

It will correctly change the name in all relevant modules.

Another new feature is the ability to replace from the Quick Search tool. The idea is similar, you search for something and see all results and then you can then replace them:



You can choose whether to replace in the current selected text, current module or all modules.
 
Last edited:

LucaMs

Expert
Licensed User
Very useful and very desired.

In the gif you can see that it is also a special implementation: it also renames routine called by CallSub and CallSubDelayed.

Great!
 

Filippo

Expert
Licensed User
Thank you Erel!
It's never too late, after 2 years comes my wish.:)
 

Martin Larsen

Active Member
Licensed User
Simply fantastic. I thought about wishing this feature just a week ago but noticed someone else had already wished it. Maybe you could read my mind, though!
 

Rusty

Well-Known Member
Licensed User
When I touch F7 or search, there is no option to rename.
Am I doing something wrong?
I'm using version 6.80
Thanks
Rusty
 

Rusty

Well-Known Member
Licensed User
I do this already. It will find the references but no "rename" option...
Thanks
 

Daestrum

Well-Known Member
Licensed User
I just tried it on B4A 6.80 and it didn't work the same as on B4J 5.50Beta and B4J 5.00

There is no rename on B4A 6.80
 
Last edited:

LucaMs

Expert
Licensed User
B4J allow you to rename "identifiers" (variable, routine names), B4A does not (now... soon, I think)
 

Rusty

Well-Known Member
Licensed User
Erel's first post says:
The next version of B4J (and all other B4X tools) will include the very first refactoring feature: Rename To.
...
Daestrum,
Can you describe how you get this to work?
I highlight a variable, touch F7 and all I get is the list of occurrences and no options to change it...
Thanks to all :)
Rusty
 

Daestrum

Well-Known Member
Licensed User
I was incorrect and corrected my posting - it does NOT work on B4A
I didn't look close enough when I tried, due to so many variables being displayed in the find all page.

Sorry if I misled you.
 
Top