eclipse / lsp4e

Language Server Protocol support in Eclipse IDE
Eclipse Public License 2.0
61 stars 54 forks source link

Rename symbol always opens a dialog #891

Open akurtakov opened 8 months ago

akurtakov commented 8 months ago

It would be nice to have inline editing (note - not asking for linked editing of all references ) so there is no extra dialog opened.

mickaelistria commented 8 months ago

It would probably be even easier to enable linked editing on rename. To do so, instead of

  1. prepareRename
  2. showDialog for newName
  3. call rename to get the edit
  4. apply the edit

we can try

  1. prepareRename
  2. callRename with another name of same length (eg myVariable becomes xxxxxxxxx), get the edit
  3. from the ranges returned in the edit, enable a linked edit in the editor.