ENVY/QA User Guide : Code Formatter : Guided Tour : Creating a Class and Method
Creating a Class and Method
Create the following class and method.
Person class
Object subclass: #Person
instanceVariableNames: 'name age '
classVariableNames: ''
poolDictionaries: ''
 
Person public class methods
named: aString age: anInteger
"Answer a new instance of the receiver whose name is aString
and age is anInteger."
^self new name: aString; age: anInteger
 
1. Open a Class Browser on the Person class.
2. Select the method #named:age:.
3. Select Edit > Format Settings....
4. When the Code Formatter Settings dialog opens, select Keywords from the left list.
5. In the right list, enable option Always split keywords.
6. Click Preview.
The code shown in the Class Browser is formatted.
7. Experiment with the other settings options by enabling or disabling them and clicking Preview.
8. When you have finished, either click Cancel to restore the text to its original form (prior to opening the dialog) or click OK to keep the changes.
Last modified date: 06/30/2015