Get the current theme's font stacks.

@param string $type (prince, epub, web ...)

@return string
187310
function getThemeFontStacks( $type ) {

		$return_value = '';

		$fullpath = $this->sass->pathToUserGeneratedSass() . "/_font-stack-{$type}.scss";

		if ( is_file( $fullpath ) ) {
			$return_value = \Pressbooks\Utility\get_contents( $fullpath );
		}

		return $return_value;
	}
831616
public function getCurrentStyleHeight(): float
    {
        if (empty($this->currentStyle)) {
            return $this->default_font_size;
        }
        $style = $this->getStyle($this->currentStyle);

        return $style['size'];
    }
452250
public static function doctype(string $type = 'html5')
    {
        $doctypes = ['xhtml11' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">',
                  'xhtml1-strict' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">',
                  'xhtml1-trans'  => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">',
                  'xhtml1-frame'  => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">',
                  'html5'	  => '<!DOCTYPE html>',
                  'html4-strict'  => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">',
                  'html4-trans'	  => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">',
                  'html4-frame'	  => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">'];

        if (isset($doctypes[$type])) return $doctypes[$type]; else return false;
    }
207842
public static function getTypeName($type)
    {
        switch ($type) {
            case self::IFD0:
                return '0';
            case self::IFD1:
                return '1';
            case self::EXIF:
                return 'Exif';
            case self::GPS:
                return 'GPS';
            case self::INTEROPERABILITY:
                return 'Interoperability';
            case self::CANON_MAKER_NOTES:
                return 'Canon Maker Notes';
            case self::CANON_CAMERA_SETTINGS:
                return 'Canon Camera Settings';
            case self::CANON_SHOT_INFO:
                return 'Canon Shot Information';
            case self::CANON_PANORAMA:
                return 'Canon Panorama Information';
            case self::CANON_PICTURE_INFO:
                return 'Canon Picture Information';
            case self::CANON_FILE_INFO:
                return 'Canon File Information';
            case self::CANON_CUSTOM_FUNCTIONS:
                return 'Canon Custom Functions';
            default:
                throw new PelIfdException('Unknown IFD type: %d', $type);
        }
    }
565438
private function getStyle(string $type, string $context): string
    {
        if (isset($this->styles[$type][$context])) {
            return $this->styles[$type][$context];
        }

        if (isset($this->styles[$type]['common'])) {
            return $this->styles[$type]['common'];
        }

        if (isset($this->styles[$type]) && is_string($this->styles[$type])) {
            return $this->styles[$type];
        }

        return $this->styles['common'];
    }
664522
public function getType(string $type): Type
    {
        if (isset($this->types[$type])) {
            return $this->types[$type];
        }

        $instance = $this->createType($type);
        $this->addType($instance);
        $this->types[$type] = $instance;

        return $instance;
    }
376233
protected function getHtmlType($type)
    {
        $map = Config::getEloquentToHtmlMap();

        if (array_key_exists($type, $map)) {
            return $map[$type];
        }

        return 'text';
    }
285039
public function getPathToScss( $type, $theme = null ) {

		if ( null === $theme ) {
			$theme = wp_get_theme();
		}

		if ( $this->isCurrentThemeCompatible( 1, $theme ) ) {
			if ( 'web' === $type ) {
				$path_to_style = realpath( $this->getDir( $theme ) . '/style.scss' );
			} else {
				$path_to_style = realpath( $this->getDir( $theme ) . "/export/$type/style.scss" );
			}
		} elseif ( $this->isCurrentThemeCompatible( 2, $theme ) ) {
			$path_to_style = realpath( $this->getDir( $theme ) . "/assets/styles/$type/style.scss" );
		} else {
			$path_to_style = false;
		}

		return $path_to_style;
	}
293768
protected function getDoctrineColumnType($type)
	{
		$type = strtolower($type);

		switch ($type) {
			case 'biginteger':
				$type = 'bigint';
				break;
			case 'smallinteger':
				$type = 'smallint';
				break;
			case 'mediumtext':
			case 'longtext':
				$type = 'text';
				break;
		}

		return Type::getType($type);
	}
237582
public static function get($type)
    {
        if (\is_string($type))
        {
            if (\defined(static::class . '::' . $type))
            {
                return \constant(static::class . '::' . $type);
            }

            if (\defined($type))
            {
                return \constant($type);
            }

            return \T_STRING;
        }

        foreach (static::constants() as $name => $value)
        {
            if ($value === $type)
            {
                return $name;
            }
        }

        $token = \token_name($type);

        if ($token === 'UNKNOWN')
        {
            return 'T_STRING';
        }

        return $token;
    }
361206
public function getColorForType($type)
    {
        // if we don't have a type return default color
        if (!isset($this->colors[$type])) {
            return Colours::DEFAULT_;
        }

        return $this->colors[$type];
    }
564352
public function message($type = null)
    {
        switch ($type) {
            case static::MESSAGE_HTML:
                return $this->_htmlMessage;
            case static::MESSAGE_TEXT:
                return $this->_textMessage;
        }

        return $this->_message;
    }
300297
public function display($type = null) : string
    {
        if ($type == self::DISPLAY_DURATION) {
            return $this->diffForHumans(self::now(), true);
        }

        if (is_null($type)) {
            $type = [self::DISPLAY_SHORT, self::DISPLAY_SHORT];
        } elseif (!is_array($type)) {
            $type = [$type, $type];
        } elseif (is_array($type)) {
            if (!isset($type[1])) {
                return Calendar::formatDate($this->toMutable(), $type[0]);
            } elseif (is_null($type[0])) {
                return Calendar::formatTime($this->toMutable(), $type[1]);
            }
        }

        return Calendar::formatDatetime($this->toMutable(), implode('|', $type));
    }
927342
public function getClassName(string $type): string
    {
        assert(isset($this->classes[$type]));
        return $this->classes[$type];
    }
242312
public static function getType($type)
    {
        $type = strtolower($type);

        if (!isset(static::$typeMapping[$type])) {
            return $type;
        }

        return static::$typeMapping[$type];
    }
1107983
public function getHtml($type = self::NO_SINGLE_RENDER_TYPE) {
        $this->_singleRenderType = $type;
        return $this->_handleDirectCall('getHtml')->toHtml();
    }
939412
public static function showContentType($type) {
        $result = '';
        try {
            $config = AgileCore::getInstance()->getConfig('statics');
            if (!empty($config[$type]['content_type'])) {
                $result = $config[$type]['content_type'];
            }
        }catch (\Exception $exception) {
            $result = 'text/html';
        }finally{
            if($result == '') {
                $result = 'text/html';
            }
        }
        return $result;
    }