Get the current theme variant
194053
def variant(self):
        ''''''
        variant = current_app.config['THEME_VARIANT']
        if variant not in self.variants:
            log.warning('Unkown theme variant: %s', variant)
            return 'default'
        else:
            return variant
1324144
def get_version():
    """"""
    with open('fades/_version.py') as fh:
        m = re.search("\(([^']*)\)", fh.read())
    if m is None:
        raise ValueError("Unrecognized version in 'fades/_version.py'")
    return m.groups()[0].replace(', ', '.')
1269350
def getCurrentFadeColor(self, bBackground):
        """"""

        fn = self.function_table.getCurrentFadeColor
        result = fn(bBackground)
        return result
236940
function getStyle(el, prop) {
    return window.getComputedStyle !== undefined ? window.getComputedStyle(el, null).getPropertyValue(prop) : el.currentStyle[prop];
  }
140941
protected function getDefaultTheme()
    {
        if (!is_null($this->default) && array_key_exists($this->default, $this->themes)) {
            return $this->themes[$this->default];
        }

        return false;
    }
1110576
def global_custom_theme(request):
    """"""
    today = datetime.datetime.now().date()
    theme = {}

    if today.month == 3 and (14 <= today.day <= 16):
        theme = {"css": "themes/piday/piday.css"}

    return {"theme": theme}
977417
public function getUpdatableThemes()
    {
        $items = [];
        $repository = $this->repository['themes'];

        // local cache to speed things up
        if (isset($this->cache[__METHOD__])) {
            return $this->cache[__METHOD__];
        }

        foreach ($this->installed['themes'] as $slug => $plugin) {
            if (!isset($repository[$slug]) || $plugin->symlink || !$plugin->version || $plugin->gpm === false) {
                continue;
            }

            $local_version = $plugin->version ?: 'Unknown';
            $remote_version = $repository[$slug]->version;

            if (version_compare($local_version, $remote_version) < 0) {
                $repository[$slug]->available = $remote_version;
                $repository[$slug]->version = $local_version;
                $repository[$slug]->type = $repository[$slug]->release_type;
                $items[$slug] = $repository[$slug];
            }
        }

        $this->cache[__METHOD__] = $items;

        return $items;
    }
201829
function getTheme(req, res, next) {
  var params = {
    appId: req.params.projectid || req.params.id
  };
  forms.getAppTheme(_.extend(req.connectionOptions, params), function(err, theme) {
    if (err) {
      return next(err);
    }

    req.appformsResultPayload = req.appformsResultPayload || {};

    if (_.isObject(req.appformsResultPayload.data) && theme && !req.getFullTheme) {
      req.appformsResultPayload.data.theme = theme._id;
    } else {
      //Want the full theme definition
      req.appformsResultPayload = {
        data: theme
      };
    }

    next();
  });
}
10840
function getThemeFromPath(dir, program, cb) {
        var configPath = path.resolve(dir, "theme.json");
        program.log(2, constants.LOG_SEV_INFO, "Attempting to read " + configPath);
        fs.readFile(configPath, { encoding: 'utf-8' }, function (err, data) {
            if (err) {
                program.log(1, constants.LOG_SEV_ERROR, "Error reading " + configPath);
                return cb(err);
            }
            var config;
            try {
                config = eval('(' + data + ')');
            } catch (e) {
                program.log(1, constants.LOG_SEV_ERROR, "Error parsing " + configPath + ".");
                program.log(2, constants.LOG_SEV_ERROR, "\n\n" + data);
                return cb(e);
            }
            var themeConf = config.about;
            if (!themeConf) {
                var errorStr = "No about section found in " + configPath;
                program.log(1, constants.LOG_SEV_ERROR, errorStr);
                return cb(new Error(errorStr));
            }
            themeConf.baseDir = dir;
            themeConf.program = program;
            cb(null, new Theme(themeConf));
        });
    }
115771
public function scanThemes()
    {

        $parentThemes = [];
        $themesConfig = config('themes.themes', []);

        foreach ($this->loadThemesJson() as $data) {
            // Are theme settings overriden in config/themes.php?
            if (array_key_exists($data['name'], $themesConfig)) {
                $data = array_merge($data, $themesConfig[$data['name']]);
            }

            // Create theme
            $theme = new Theme(
                $data['name'],
                $data['asset-path'],
                $data['views-path']
            );

            // Has a parent theme? Store parent name to resolve later.
            if ($data['extends']) {
                $parentThemes[$theme->name] = $data['extends'];
            }

            // Load the rest of the values as theme Settings
            $theme->loadSettings($data);
        }

        // Add themes from config/themes.php
        foreach ($themesConfig as $themeName => $themeConfig) {

            // Is it an element with no values?
            if (is_string($themeConfig)) {
                $themeName = $themeConfig;
                $themeConfig = [];
            }

            // Create new or Update existing?
            if (!$this->exists($themeName)) {
                $theme = new Theme($themeName);
            } else {
                $theme = $this->find($themeName);
            }

            // Load Values from config/themes.php
            if (isset($themeConfig['asset-path'])) {
                $theme->assetPath = $themeConfig['asset-path'];
            }

            if (isset($themeConfig['views-path'])) {
                $theme->viewsPath = $themeConfig['views-path'];
            }

            if (isset($themeConfig['extends'])) {
                $parentThemes[$themeName] = $themeConfig['extends'];
            }

            $theme->loadSettings(array_merge($theme->settings, $themeConfig));
        }

        // All themes are loaded. Now we can assign the parents to the child-themes
        foreach ($parentThemes as $childName => $parentName) {
            $child = $this->find($childName);

            if ($this->exists($parentName)) {
                $parent = $this->find($parentName);
            } else {
                $parent = new Theme($parentName);
            }

            $child->setParent($parent);
        }
    }
135830
private Style getStyle() {
        SharedPreferences sharedPreferences =
                PreferenceManager.getDefaultSharedPreferences(getActivity());
        String key = getString(R.string.bottom_sheet_style_preference_key);
        String defaultValue = getString(R.string.bottom_sheet_style_preference_default_value);
        String style = sharedPreferences.getString(key, defaultValue);

        switch (style) {
            case "list":
                return Style.LIST;
            case "list_columns":
                return Style.LIST_COLUMNS;
            default:
                return Style.GRID;
        }
    }
319718
function convertTheme(str) {
  var theme = plist.parse(str)
  theme.settings = convertArray(theme.settings)
  return theme
}
484227
public function getSiteTheme(){
		$theme = $this->Theme;
		if (!$theme) {
			$theme = Config::inst()->get(SSViewer::class, 'theme');
		}
		$this->extend('updateGetSiteTheme', $theme);
		return $theme;
	}
1079669
function getThemeSupportedLanguages() {

		$return_value = false;

		$fullpath = get_stylesheet_directory() . '/theme-information.php';

		if ( is_file( $fullpath ) ) {

			require( $fullpath );

			if ( ! empty( $supported_languages ) ) {
				$return_value = $supported_languages;
			}
		} else {
			$return_value = get_theme_support( 'pressbooks_global_typography' );
		}

		return $return_value;
	}
764745
def get_html_theme_path():
    """"""
    theme_path = os.path.abspath(os.path.dirname(__file__))
    return [theme_path]
112363
def get_html_theme_path():
    
    return os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
802777
def version():
    
    click.echo(
        click.style(
            "F.A.B Version: {0}.".format(current_app.appbuilder.version),
            bg="blue",
            fg="white"
        )
    )