亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? font.h

?? 這是一款2d游戲引擎
?? H
?? 第 1 頁 / 共 2 頁
字號(hào):
	//param str: String to get the width of.
	//param start: A starting iterator, inclusive.
	//param end: An ending iterator, exclusive.
	//param max_size: Same effect as the size of the dest rectangle passed to draw(), for word wrapping and height truncating.
	int get_width(unsigned char letter) const;
	
	int get_width(
		const std::string &str,
		CL_Size max_size = CL_Size(0,0)) const
		{return get_size(str, max_size).width;}
	
	int get_width(
		std::string::const_iterator start,
		std::string::const_iterator end,
		CL_Size max_size = CL_Size(0,0)) const
		{return get_size(start, end, max_size).width;}
	
	//: Returns the drawn size of a string.
	//return: The size in pixels.
	//param letter: Character to get the size of. If unrecognized, returns space width.
	//param str: String to get the size of.
	//param start: A starting iterator, inclusive.
	//param end: An ending iterator, exclusive.
	//param max_size: Same effect as the size of the dest rectangle passed to draw(), for word wrapping and height truncating.
	CL_Size get_size(unsigned char letter) const
		{return CL_Size(get_width(letter), get_height());}
	
	CL_Size get_size(
		const std::string &str,
		CL_Size max_size = CL_Size(0,0)) const
		{return get_size(str.begin(), str.end(), max_size);}
	
	CL_Size get_size(
		std::string::const_iterator start,
		std::string::const_iterator end,
		CL_Size max_size = CL_Size(0,0)) const;
	
	//: Calculate the rectangle that would be occupied by a draw operation.
	//param str: The input string to process.
	//param start: String position to begin processing at, inclusive.
	//param end: String position to end processing at, exclusive.
	//param x, y: Anchor position to simulate draw at. Actual position depends on the alignment mode.
	//param dest: Rectangle to draw text in. The text will be word-wrapped against delimiters to fit inside the rectangle.
	//- <p> You can specify a dest rectangle with a width or height of zero or less to disable word wrapping
	//- or height truncating, respectively. </p>
	CL_Rect bounding_rect(
		int x,
		int y,
		const std::string &str) const
		{return bounding_rect(CL_Rect(x, y, x, y), str.begin(), str.end());}
	
	CL_Rect bounding_rect(
		CL_Rect dest,
		const std::string &str) const
		{return bounding_rect(dest, str.begin(), str.end());}
	
	CL_Rect bounding_rect(
		int x,
		int y,
		std::string::const_iterator start,
		std::string::const_iterator end) const
		{return bounding_rect(CL_Rect(x, y, x, y), start, end);}
	
	CL_Rect bounding_rect(
		CL_Rect dest,
		std::string::const_iterator start,
		std::string::const_iterator end) const;
	
	//: Returns whether or not a glyph exists for a given character
	//- <p> This is the same as checking if get_width(chr) returns zero. </p>
	bool is_glyph(unsigned char chr) const;
	
	//: Resource owning this font, if any.
	CL_Resource resource;
	
//! Operations:
public:
	//: Copy assignment operator.
	CL_Font &operator =(const CL_Font &copy);
	
        //: Return true if the CL_Font object is valid
        operator bool() const;

	//: Draws text to a graphic context.
	//return: The number of glyphs that were drawn.
	//param str: The input string to draw.
	//param start: String position to begin drawing at, inclusive.
	//param end: String position to end drawing at, exclusive.
	//param x, y: Anchor position to draw at. Actual drawing position depends on the alignment mode.
	//param gc: Graphic context on which to draw. If null, will use CL_Display's current graphic context.
	//param dest: Rectangle to draw text in. The text will be word-wrapped against delimiters to fit inside the rectangle.
	//- <p> You can specify a dest rectangle with a width or height of zero or less to disable word wrapping
	//- or height truncating, respectively. </p>
	int draw(
		int x,
		int y,
		const std::string &str,
		CL_GraphicContext *context = 0) const
		{return draw(CL_Rect(x, y, x, y), str.begin(), str.end(), context);}
	
	int draw(
		CL_Rect dest,
		const std::string &str,
		CL_GraphicContext *context = 0) const
		{return draw(dest, str.begin(), str.end(), context);}
	
	int draw(
		int x,
		int y,
		std::string::const_iterator start,
		std::string::const_iterator end,
		CL_GraphicContext *context = 0) const
		{return draw(CL_Rect(x, y, x, y), start, end, context);}
	
	int draw(
		CL_Rect dest,
		std::string::const_iterator start,
		std::string::const_iterator end,
		CL_GraphicContext *context = 0) const;
	
	//: Inserts data into a CL_GlyphBuffer, treating the glyphs already there as part of a previous draw_to_gb().
	//return: The number of glyphs that were inserted. This could be negative if it backtracks.
	//param str: The input string to draw.
	//param start: String position to begin drawing at, inclusive.
	//param end: String position to end drawing at, exclusive.
	//param max_size: Sets size for word wrapping and height truncating. Either can be zero to disable that feature.
	//param gb: The glyph buffer to mess with.
	//- <p> The CL_GlyphBuffer's contents (the glyphs vector, the font markers map, and the effects maps),
	//- if any, must not have been created/altered by anything but CL_Font::draw_to_gb() and/or CL_TextStyler::draw_to_gb()
	//- for this method to work.</p>
	//- <p> If you are doing draw_to_gb several sequential times
	//- to the same CL_GlyphBuffer, then you must pass the same maximum width to each call of
	//- draw_to_gb. </p>
	//- <p> Each glyph inserted into the CL_GlyphBuffer corresponds with exactly one character of the input string, with
	//- the order in the vector and the order in the string being the same. That is, if you start out with an empty CL_GlyphBuffer,
	//- run this method on it, and afterwords the CL_GlyphBuffer contains 100 glyphs, then you know the first 100 characters
	//- of the source string range were processed. This includes whitespace and newline characters.</p>
	//- <p> If you call this method on a CL_GlyphBuffer with a last line that is center-justified or left-justified, be aware
	//- that there's no way for this function to differentiate that line from a left-justified line with an indent, and it
	//- always assumes the latter. </p>
	//- <p> You can tell when you've filled the buffer up to the height in max_size when a call to this method returns
	//- anything less than the size of the string. There's also the chance that it will backtrack and return
	//- a negative value if it runs out
	//- of vertical space in the process of wrapping a just-completed word; this is still a sign that you've
	//- ran out of vertical space.</p>
	int draw_to_gb(
		const std::string &str,
		CL_GlyphBuffer &gb,
		CL_Size max_size = CL_Size(0,0)) const
		{return draw_to_gb(str.begin(), str.end(), gb, max_size);}
	
	int draw_to_gb(
		std::string::const_iterator start,
		std::string::const_iterator end,
		CL_GlyphBuffer &gb,
		CL_Size max_size = CL_Size(0,0)) const;
	
	//: Draws a single glyph to a given spot.
	//param x, y: The upper-left coordinates of where to draw the glyph.
	//param chr: The character to draw the glyph of.
	//param ang: The amount to rotate the glyph by. The hotspot is set with CL_Font::set_glyph_rot_hotspot().
	//- <p> If there is no glyph for the given character, then nothing is drawn. </p>
	void draw_glyph(int x, int y, unsigned char chr, float ang = 0.0);
	
	//: Sets delimiters string.
	//- <p> This string contains characters (other than newline) that divide words apart.
	//- Do not include newline in this string, it's an implicit delimiter.</p>
	void set_delims(const std::string &delims);
	
	//: Sets width offset.
	//- <p> The width offset can be used to kern glyphs together or spread them apart. </p> 
	void set_width_offset(int offset);
	
	//: Sets height offset.
	//- <p> The height offset can be used to create space between lines, or to merge them together. </p> 
	void set_height_offset(int offset);
	
	//: Sets scale for x and y directions individually.
	//- <p> 1.0f is normal scale, 2.0f is twice the size, etc. </p>
	void set_scale(float x, float y);
	
	//: Sets transparency.
	//- <p> 0.0f is full transparency, and 1.0f is full visibility. </p>
	void set_alpha(float alpha);
	
	//: Sets the color.
	//- <p> Alpha 0.0f is full transparency, and 1.0f is full visibility (solid). </p>
	void set_color(float r, float g, float b, float a = 1.0f);
	void set_color(const CL_Color& c) {set_color(float(c.get_red())/255.0f,float(c.get_green())/255.0f,float(c.get_blue())/255.0f,float(c.get_alpha())/255.0f);}
	
	//: Sets blending functions.
	void set_blend_func(CL_BlendFunc src, CL_BlendFunc dest);
	
	//: Sets glyph rotation hotspot.
	//- <p> This is for the optional angle parameter to draw_glyphs(). </p>
	void set_glyph_rot_hotspot(CL_Origin origin, int x = 0, int y = 0);
	
	//: Sets translation hotspot.
	void set_alignment(CL_Origin origin, int x = 0, int y = 0);
	
//! Implementation:
private:
	CL_LazyCopyPtr<CL_Clonable, CL_Font_Generic> impl;
};

#endif

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲国产精品成人综合| 精品1区2区3区| 国产欧美精品一区| 国产精品性做久久久久久| 国产日韩欧美a| 99国内精品久久| 亚洲精品第一国产综合野| 欧美精品久久99| 精品一区二区在线视频| 中文在线免费一区三区高中清不卡| 成人免费观看视频| 亚洲一区二区三区四区在线| 欧美精品v日韩精品v韩国精品v| 久久不见久久见中文字幕免费| 国产色婷婷亚洲99精品小说| 91麻豆.com| 蜜臀精品一区二区三区在线观看| 国产欧美日韩另类视频免费观看 | 欧美日韩第一区日日骚| 免费在线观看一区二区三区| 国产日韩欧美精品电影三级在线| 色悠悠亚洲一区二区| 蜜桃一区二区三区在线观看| 欧美激情一区不卡| 欧美丰满一区二区免费视频| 国产一区二区三区四区在线观看| 亚洲精品国产精华液| 日韩欧美国产综合一区| 91丝袜呻吟高潮美腿白嫩在线观看| 日韩高清不卡一区| 亚洲色图清纯唯美| 久久综合久久综合久久综合| 在线欧美一区二区| 国产91综合网| 男男gaygay亚洲| 亚洲精品乱码久久久久久| 久久美女艺术照精彩视频福利播放| 欧洲人成人精品| 成人午夜免费视频| 精品一区二区在线视频| 亚洲一区二区三区四区在线| 中文字幕av一区二区三区| 日韩一区二区三区在线观看| 91福利国产精品| 国产成人综合在线| 久久99蜜桃精品| 午夜精品123| 亚洲日本一区二区三区| 国产视频一区二区三区在线观看| 91精品国产综合久久久久| 91视频免费看| 99久久久无码国产精品| 久久成人18免费观看| 无码av中文一区二区三区桃花岛| 亚洲欧美日韩在线| 国产精品久久久久久久久免费桃花 | 国产欧美一区二区在线| 欧美一区永久视频免费观看| 欧美做爰猛烈大尺度电影无法无天| 国产成人av自拍| 国产在线乱码一区二区三区| 免费观看日韩电影| 日本不卡不码高清免费观看| 亚洲福利一二三区| 亚洲黄色录像片| 一区二区三区免费网站| 亚洲欧洲日韩av| 国产精品麻豆欧美日韩ww| 久久久久久毛片| 国产亚洲精品aa| 亚洲国产成人午夜在线一区| 久久精品人人做人人爽97| 国产亚洲制服色| 中文字幕免费不卡| 中文字幕不卡三区| 亚洲欧洲99久久| 亚洲男同1069视频| 亚洲一区免费视频| 亚洲成人黄色影院| 日本不卡一区二区| 另类调教123区| 国产一区二区三区免费看| 国产一区二区三区电影在线观看| 国产伦精品一区二区三区视频青涩 | 欧美一区二区福利在线| 91麻豆精品国产自产在线观看一区 | 欧美专区亚洲专区| 欧美三级蜜桃2在线观看| 欧美日韩国产bt| 日韩精品在线网站| 久久久久成人黄色影片| 国产精品久久久久四虎| 亚洲最新视频在线观看| 视频在线观看国产精品| 狠狠色丁香婷婷综合| 国产999精品久久| 色天天综合色天天久久| 7777精品伊人久久久大香线蕉最新版| 91精品国产综合久久久蜜臀图片| 精品国产99国产精品| 国产婷婷色一区二区三区在线| 中文字幕一区二区三区不卡 | 99这里只有久久精品视频| 在线视频欧美精品| 日韩亚洲欧美在线观看| 国产视频一区在线观看| 亚洲日本一区二区| 免费xxxx性欧美18vr| 国产a区久久久| 欧美人体做爰大胆视频| 国产日韩av一区二区| 一区二区三区国产精品| 国产永久精品大片wwwapp| 色婷婷激情综合| 精品三级av在线| 亚洲精品乱码久久久久| 国模无码大尺度一区二区三区| 一本色道综合亚洲| 久久综合九色综合97婷婷女人| 亚洲黄一区二区三区| 久久99久久99精品免视看婷婷| 99精品国产热久久91蜜凸| 日韩欧美在线影院| 综合久久给合久久狠狠狠97色| 日韩电影一区二区三区| 91视频你懂的| 国产欧美一区二区在线| 日韩成人免费电影| 色噜噜久久综合| 久久久噜噜噜久噜久久综合| 亚洲va在线va天堂| 99re热这里只有精品视频| 亚洲精品一区二区三区福利| 一区二区三区**美女毛片| 国产成人亚洲综合a∨猫咪| 8x8x8国产精品| 亚洲美女屁股眼交3| 成人一区在线看| 精品日韩欧美在线| 午夜电影一区二区| 一本色道亚洲精品aⅴ| 国产日韩精品一区| 国内成人免费视频| 日韩一区二区免费在线观看| 一级女性全黄久久生活片免费| 国产·精品毛片| 欧美成人欧美edvon| 三级久久三级久久久| 欧美三级三级三级| 亚洲一区二区欧美| 日本精品一区二区三区高清| 亚洲国产成人自拍| 成人午夜激情片| 中文幕一区二区三区久久蜜桃| 精品中文字幕一区二区| 日韩欧美一级精品久久| 日韩成人午夜精品| 欧美一激情一区二区三区| 日韩高清不卡一区| 日韩一级完整毛片| 免费黄网站欧美| 欧美一级黄色大片| 久久超碰97中文字幕| 久久品道一品道久久精品| 国产一区二区在线影院| 久久久久成人黄色影片| 国产成人激情av| 一区精品在线播放| 一本色道久久综合亚洲91| 亚洲在线中文字幕| 欧美日韩成人综合天天影院| 亚洲动漫第一页| 91精品国产色综合久久ai换脸| 免费视频最近日韩| 久久综合九色综合欧美就去吻| 国产高清在线精品| 国产精品美女久久久久久久网站| 92国产精品观看| 亚洲精品第1页| 91麻豆精品久久久久蜜臀| 九九国产精品视频| 中文无字幕一区二区三区| 99久久免费视频.com| 亚洲一区欧美一区| 欧美不卡123| 成人激情校园春色| 一二三四社区欧美黄| 欧美日韩精品系列| 精品亚洲成a人在线观看| 国产精品欧美综合在线| 欧美在线观看你懂的| 秋霞成人午夜伦在线观看| 久久婷婷综合激情| 色老综合老女人久久久| 日韩精品国产欧美| 中文字幕乱码一区二区免费| 欧美制服丝袜第一页| 久久av资源站| 亚洲精品视频免费观看| 欧美电视剧在线观看完整版|