renameUI
string string
renameUI は 「元に戻す」が可能、「照会」が不可能、「編集」が不可能 です。
このコマンドは、1 番目の引数として渡された UI オブジェクトの名前を、2 番目の引数として指定された新しい名前に変更します。新しい名前が重複しているか有効でない場合、名前の変更は失敗して古い名前が返されます。string | 新しい名前。名前の変更に失敗した場合は古い名前。 |
// Create a window with a single button. // string $window = `window`; columnLayout; button -label "Example" exampleButton; showWindow $window; // Edit the button label. // button -edit -label "New Label" exampleButton; // Rename the button. // renameUI exampleButton newButton; // Query the button label using the new object name. // button -query -label newButton;