Hi!
As Harris is currently working on the latex bundle, I have a suggestion:
I sometimes change the header of a section, and so also the label. Even for figures I sometimes change the label. Then I have to search for all references for these labels. So I would be glad if there would be a Rename refactoring for labels and references.
Helge
On Dec 27, 2006, at 2:04 AM, Helge Hartmann wrote:
Hi!
As Harris is currently working on the latex bundle, I have a suggestion:
I sometimes change the header of a section, and so also the label. Even for figures I sometimes change the label. Then I have to search for all references for these labels. So I would be glad if there would be a Rename refactoring for labels and references.
That shouldn't be too hard to do, certainly easy for just one file. My concern would be with projects, where multiple files would need to be changed, most of them not visible to the user at the time. So first of all there is a danger of something going wrong on the rewriting, and the user possibly losing a lot of data, without that being obvious at first. I would feel much safer just relying on a simple project search and replace. Unfortunately we can't really record a macro to do exactly that project search and replace. I agree though that such a command would be nice touch, and it shouldn't be too hard to get something workable reasonably fast using the LaTeXUtils library. A bit difficult to implement in a safe way though. Any reason you don't just want to do a simple project search and replace? It is not that much slower really.
It is interesting to me though that you find the need to change the section label when the section title changes. My labels tend to be shorter than the section titles, and usually try to refer to what that section is about. And it doesn't happen too often that I would change what a section is about. So I rarely find the need for such a refactoring myself.
Helge
Haris