ModelMaker Code Explorer 4.00
Delphi 2006 support
- New Pascal Language Mode: Delphi 2006 Win32. Enables new Win32 syntax features in editor and parser.
- Record helper support.
- Win32: Static class fields supported
- Win32: Methods in records supported
- Win32: Operator overloading for records
C# 2.0 support
- New C# v2 language mode enables new C# 2 syntax features in editor and parser. Language mode C# v1 and C# v2 can be selected on Properties | C# |Parsing tab.
- Partial class, record and interface support.
- Anonymous method support
- Extern alias support, including :: to reference extern alias members.
- Static classes support.
- Generic types support.
- Property accessor visibility support.
Generic new features
- Try .. finally wizard: acts like a smart surround template, looking at the preceding code to determine the code for the finally block. Customizable using a look-up list in file TryFinallyWizard.txt in the shared directory, for example "C:\Program Files\ModelMakerTools\Shared". Check this article for details. Default shortcut is Ctrl+Alt+J (similar to Delphi's Ctrl+J to invoke a template). The Pascal wizard code snippets are customizable. Check Properties | Pascal | Code Snippets.
- Surround with Default Block Wizard: acts like a smart surround template to enclose the selection or line in a begin end or { }.block. Indention is smart and derived from the code preceding the selection. Default shortcut is Ctrl+Shift+B.
- Member search bar in Members view filter bar. Filters members on case insensitive (partial) name. String can be auto cleared when activating contents view and/ or members view. Check General|Display options tab. In Explorer and IDE Editor keyboard shortcut Ctrl+1 sets focus to the search bar. In the Search bar the Enter key selects the first member and then either sets focus to the members list, or if there's only a single member, invokes the "locate implementation" command and moves focus to the editor. Alt+Enter works similar, except that it invokes "locate declaration". The Up and Down arrow keys select the first member in the members view and set focus to the members list.
- Add Indexer: adds a fully implemented indexer (array) property with just a few clicks. Check the article for more details.
- Extract Property, similar as Extract Method but creates a property with read access method instead of a plain method. Default shortcut Shift+Alt+X
- Interfaces supported by classes may be displayed in the Classes view. Clicking the interface or icon navigates to the interface declaration, similar to how ModelMaker Code Explorer navigates to ancestors.
- Replace Method with Method Object refactoring. Creates a new class containing a copy of the selected method plus a backpointer. Inserts code to instantiate and call the new class. The first step to decompose a long method into other methods on the same object.
- Default Sort Class at cursor position available as IDE editor refactoring. Keyboard shortcut can be assigned in Keybindings tab.
- Sort selected members: applies the default sorting scheme to members selected in the editor - not the members view. Available for C# only
- Add Local Var allows initializing local variable at method entrance. Creational Wizard logic is used to suggest variable initialization code.
- Property Access Code for existing access methods can be replaced with a new access code snippets (pascal only).
- IntelliReplace available for renamed methods and properties. Because IntelliReplace replaces all identifiers with Former Name, not just references to the renamed method or property, it should only be used for uncommon names. IntelliReplacing identifiers like Add and Delete might cause unwanted replacements. Therefore IntelliReplace for methods and properties always shows a confirmation dialog that allows selecting a class (including declaration) or module rename scope.
- IntelliReplace propagates Renamed Field in class interface (for example property declarations).
- Breakup Property removes the property declaration without deleting the access members. Available from members view pop up menu "Convert".
- Documentation Pane font can be adjusted on Properties General | Documentation tab.
- Reverse Assignment: reverses the left and right expressions in an := (pascal) or = (C#) statement.
- Toggle Comment Selection comments out the selected text with a //-style comment, or uncomments selected //-style comments
- Paste Prototype: (pascal) allows pasting methods while applying one of the following options:
- Clear method implementation: removes method implementation while pasting, inserting just the implementation header
- Insert inherited call, used in combination with Clear method implementation.
- Mark virtual methods override, used to paste methods declared as virtual as overrides.
- Change visibility, used to paste interface members (with no or default visibility) into a class specifying new visibility.
- Add/Edit Method dialog allows adding implementation snippets to new or existing methods.
- Extract Method dialog allows changing the way the original code is treated. Defaults to setting as defined in Properties|Language|Editing tab.
- Sorting restores the entity at editor position.
- Declaration hints: "Unwrap Declaration" is available in the members view when declaration hints are displayed (pascal only). Unwraps the selected declarations into a single line.
Navigation History and Favorites
- Members can be marked as "Favorite". Favorite members appear first in the member list and have a different background color (default yellow). Using favorites helps repeated navigating within the same set of members (methods). For example, if you're working on a specific feature, you usually need to navigate between several methods involved in the feature implementation. Marking these methods as favorite, groups them and brings them to the top of members view, speeding up navigation. To toggle a member's favorite state, use Ctrl+Shift+F in either the Members view or in the IDE editor. Favorites respect the filter settings: a favorite method is not visible if methods are suppressed. A member's Favorite state is (within limitations) persistent between sessions. Also favorites are usually restored after (manual) editing the source file. However, in certain editing scenarios a favorite can be reset to normal. Particularly after changing both the name for the containing class and the member name at once. The favorites background color can be customized using the registry settings.
- A navigation history is available as a global navigation multiple files spanning history from the classes view. Similar a history filtered for the current class is available in the members view. Entities can be added automatically and or manually to the history. By default methods at the editor cursor position are added on a sampling base. Optionally also clicking on methods and properties in the members view automatically adds them to the history. To manually add an item to the history, use Ctrl+H in either members view or the IDE editor. The history acts as a list of recently visited class/ members, not a forward / backward stack. The history can be customized in the new Properties | History tab. Note: IDE Editor Global History and adding sampled methods is not working if the explorer window is invisible.
- "Back to Last Editing Position": positions the editor on the last modified source. Available from explorer classes view toolbar and from the main MMX | Navigation menu.
- A bookmark is (optionally) dropped when creating a new method, by default drop bookmark #9. Check Properties | History tab.
Creational Wizard
The Creational Wizard is used to insert field and property initialization code snippets in a constructor. Optionally a parameter is added to the constructor parameter list to initialize a field or property. You may select an existing constructor or create a new one. Similar finalization snippets can be inserted in a destructor.
- The Field and Property dialogs have a Creational Wizard Tab that is used to initialize the field or property.
- A separate Creational Wizard dialog allows selecting multiple fields or properties at once. This wizard is available from the Wizards pop up menus (Contents and Members view) and IDE main MMX menu.
- For Win32 designer classes (forms and datamodules) code can be inserted in existing OnCreate and OnDestroy eventhandlers instead of constructors / destructors.
- Presets are available to help fill in initialization / finalization code snippets
- Composite inserts code to instantiate and finalize a member. For example List := TList.Create; or list = New List(); For Pascal also destructor code is inserted like FreeAndNil(List);
- Aggregate adds a parameter to the constructor parameter list and assigns the parameter value to the member. No destructor code is inserted.
- Assign Default Value inserts an assignment. For pascal properties with a RTTI default value, the default value is assigned.
- Owned adds finalization code to a destructor, like FreeAndNil(List);
- All code is fully editable and the suggested snippets are customizable.
- Read more on this feature in this article.
Source Region support
- Sorting and rearranging leaves source regions intact. Sorting can move regions to top or bottom and recursively sort inside regions. Options can be found on Properties | [Language] | Sorting tab.
- Regions inside classes can be displayed in the classes view. Check "show contained regions" button on the classes view toolbar. Currently the displayed regions only navigate to the region declaration. When selecting a region, no members are displayed.
Solved bugs
- Introduce Parameter Object would add "Data: TData" to the method's parameter list rather than the new parameters class. Solved.
- Copy Full Name for class members would just copy the member name. Solved.
- Defining a default external file for the module string conversion wizard, would clear this file each time the Properties dialog OK button was clicked. Solved.
- Some dialogs would appear bad when using large fonts. Solved


Entity Insight