The Need for a Smarter SyncEdit

When Mike Rozlog was visiting Calgary Alberta during the Rad Studio XE Tour one of the many features he demonstrated was SyncEdit. While SyncEdit is pretty cool from a visual standpoint, I don’t get why Mike was saying it’s such a great feature. First of all you have to select the scope in which to apply SyncEdit. It doesn’t even default to the entire unit, or the method in which the cursor is positioned. Then you have to locate the identifier(s) you wish to change and type in the new names. This isn’t really so different than using Ctrl+R to do a search and replace.  In fact, in most cases Ctrl+R is faster even if it doesn’t have the cool visual feedback.

Now if SyncEdit could be automatically invoked the moment you started modifying a method prototype in either the implementation or interface section that would be cool. It would be even better if the IDE could use that technology to create the prototype in the interface section when you added methods in the implementation section.

BTW, Mike, if you’re reading this, I’m still waiting for the answers to the questions I posed during that meeting, and later followed up with in an email. I know you’re busy, but the Tour was in Calgary on Sept. 9, 2010.

Tags:

5 Responses to “The Need for a Smarter SyncEdit”

  1. Dorin Duminica Says:

    SyncEdit is nice but not for entire unit, if you have two identifier i.e.
    a) doSomething;
    b) doSomethingElse;
    and I wish to replace doSomething with NewIdentifier, then I end up having NewIdentifierElse, whereas using SyncEdit, you don’t get into this situation.
    Overall, I get your point, I’m using CTRL+R 90%+ of the time mainly because SyncEdit is pretty buggy…

  2. Jolyon Smith Says:

    @Dorin - if you mean that SyncEdit is better than search/replace in your “doSomething/NewIdentifier” example, simply turning on “Whole words only” avoids that problem with search/replace

  3. Isopod Says:

    “It would be even better if the IDE could use that technology to create the prototype in the interface section when you added methods in the implementation section.”
    You can do that with Ctrl+Shift+C (works both ways).

  4. Larry Hengen Says:

    @IsoPod - The issue is that Ctrl+Shift+C does not allow you to specify the scope of the method and it doesn’t do anything in the case of changing a method prototype. Once you create a method definition and implementation, Delphi doesn’t help you at all in maintaining them, and they must be kept in sync. That was kind of the whole idea of the post. SyncEdit should be capable of at least syncing edits to the one thing a Delphi developer is constantly having to deal with - altering a method signature.

  5. Jacob Thurman Says:

    The “rename” refactorings in Castalia are very similar to a more intelligent scope-aware SyncEdit: http://twodesk.com/castalia/delphi-refactoring.html

    (Disclaimer: I’m the creator of Castalia)

Leave a Reply