Difference between revisions of "Font (简体中文)"

(Created page with "{{notice|这是一个粗鲁的翻译,它的目的是为了方便中国中学英语水平的love2d的粉丝查看的 要知道翻译像number x return the value of x的东西...")
 
Line 1: Line 1:
 
{{notice|这是一个粗鲁的翻译,它的目的是为了方便中国中学英语水平的love2d的粉丝查看的  
 
{{notice|这是一个粗鲁的翻译,它的目的是为了方便中国中学英语水平的love2d的粉丝查看的  
 
要知道翻译像number x return the value of x的东西很浪费时间的。}}  
 
要知道翻译像number x return the value of x的东西很浪费时间的。}}  
将定义字符绘制在屏幕上
+
定义字符绘制在屏幕上的形状
== Types ==  
+
== Constructors ==
{|class="wikitable"
+
{{#ask: [[Category:Functions]] [[Constructs::Font]] [[Concept:Current]]
|-
+
| headers=hide
|[[love.graphics.newFont]]|| 创建新字体.  
+
| default=None.
|-
+
| format=template
|[[love.graphics.newImageFont]]|| 通过加载图像文件创建字体
+
| template=ListingFields
|-
+
| introtemplate=ListingIntro
|}  
+
| outrotemplate=ListingOutro
== Functions ==  
+
| ?Description
{|class="wikitable"
+
| ?PrettySince
|-
+
| ?PrettyRemoved
|[[Font:getHeight]]|| 取高.
+
}}
|-
+
== Functions ==
|[[Font:getLineHeight]]||取行宽值.
+
{{#ask: [[Category:Functions]] [[parent::Font||Object]] [[Concept:Current]]
|-
+
| headers=hide
|[[Font:getWidth]]|| 取宽.
+
| format=template
|-
+
| template=ListingFields
|[[Font:getWrap]]|| 返回字体包括多少行 0.0
+
| introtemplate=ListingIntro
|-
+
| outrotemplate=ListingOutro
|[[Font:setLineHeight]]|| 设置行高
+
| ?Description
|-
+
| ?PrettySince
|[[Object:type]]|| 取类型.
+
| ?PrettyRemoved
|-
+
}}
|[[Object:typeOf]]|| 检查一个对象是否是某型
+
 
|}
 
[[Category:Modules]]
 
{{#set:Description=将定义字符绘制在屏幕上.}}  
 
 
== Supertypes ==
 
== Supertypes ==
 
[[Object]]
 
[[Object]]
 
== See Also ==
 
== See Also ==
 
* [[parent::love.graphics (简体中文)]]
 
* [[parent::love.graphics (简体中文)]]
 +
[[Category:Types]]
 +
{{#set:Description=定义字符绘制在屏幕上的形状}}
 +
{{#set:Since=000}}
 
== Other Languages ==  
 
== Other Languages ==  
 
{{i18n|love.font}}
 
{{i18n|love.font}}

Revision as of 13:39, 27 October 2019

O.png 这是一个粗鲁的翻译,它的目的是为了方便中国中学英语水平的love2d的粉丝查看的

要知道翻译像number x return the value of x的东西很浪费时间的。

 


定义字符绘制在屏幕上的形状

Constructors

love.graphics.newFont Creates a new Font from a TrueType Font or BMFont file.
love.graphics.newImageFont Creates a new Font by loading a specifically formatted image. Added since 0.2.0

Functions

Font:getAscent Gets the ascent of the Font in pixels. Added since 0.9.0
Font:getBaseline Gets the baseline of the Font in pixels. Added since 0.9.0
Font:getDPIScale Gets the DPI scale factor of the Font. Added since 11.0
Font:getDescent Gets the descent of the Font in pixels. Added since 0.9.0
Font:getFilter Gets the filter mode for a font. Added since 0.9.0
Font:getHeight Gets the height of the Font in pixels.
Font:getKerning Gets the kerning between two characters in the Font. Added since 11.4
Font:getLineHeight Gets the line height.
Font:getWidth Determines the width of the given text.
Font:getWrap Gets formatting information for text, given a wrap limit. Added since 0.7.0
Font:hasGlyphs Gets whether the Font can render a character or string. Added since 0.9.0
Font:setFallbacks Sets other Fonts to use if this Font doesn't have a specific character. Added since 0.10.0
Font:setFilter Sets the filter mode for a font. Added since 0.9.0
Font:setLineHeight Sets the line height.
Object:release Immediately destroys the object's Lua reference. Added since 11.0
Object:type Gets the type of the object as a string.
Object:typeOf Checks whether an object is of a certain type.

Supertypes

Object

See Also


Other Languages