original_string: public function getLayoutOptions()
      {
          if (!($theme = Theme::getEditTheme())) {
              throw new ApplicationException(Lang::get('cms::lang.theme.edit.not_found'));
          }
  
          $layouts = Layout::listInTheme($theme, true);
          $result = [];
          $result[null] = Lang::get('cms::lang.page.no_layout');
  
          foreach ($layouts as $layout) {
              $baseName = $layout->getBaseFileName();
  
              if (FileDefinitions::isPathIgnored($baseName)) {
                  continue;
              }
  
              $result[$baseName] = strlen($layout->name) ? $layout->name : $baseName;
          }
  
          return $result;
      }
code: public function getLayoutOptions()
      {
          if (!($theme = Theme::getEditTheme())) {
              throw new ApplicationException(Lang::get('cms::lang.theme.edit.not_found'));
          }
  
          $layouts = Layout::listInTheme($theme, true);
          $result = [];
          $result[null] = Lang::get('cms::lang.page.no_layout');
  
          foreach ($layouts as $layout) {
              $baseName = $layout->getBaseFileName();
  
              if (FileDefinitions::isPathIgnored($baseName)) {
                  continue;
              }
  
              $result[$baseName] = strlen($layout->name) ? $layout->name : $baseName;
          }
  
          return $result;
      }
code_tokens: public function getLayoutOptions ( ) { if ( ! ( $ theme = Theme :: getEditTheme ( ) ) ) { throw new ApplicationException ( Lang :: get ( 'cms::lang.theme.edit.not_found' ) ) ; } $ layouts = Layout :: listInTheme ( $ theme , true ) ; $ result = [ ] ; $ result [ null ] = Lang :: get ( 'cms::lang.page.no_layout' ) ; foreach ( $ layouts as $ layout ) { $ baseName = $ layout -> getBaseFileName ( ) ; if ( FileDefinitions :: isPathIgnored ( $ baseName ) ) { continue ; } $ result [ $ baseName ] = strlen ( $ layout -> name ) ? $ layout -> name : $ baseName ; } return $ result ; }
docstring: Returns a list of layouts available in the theme.
  This method is used by the form widget.
  @return array Returns an array of strings.
docstring_tokens: Returns a list of layouts available in the theme . This method is used by the form widget .