图形对象Properties
您可以通过设置其属性来控制特定图形对象的行为和外观。要设置属性,请从创建它的函数中返回对象作为输出参数。例如,plot
function returns a chart line object. Then, use dot notation to view and set properties.
p = plot(1:10,1:10); p.LineWidth = 3;
情节(1:10,1:10,'lineWidth',3)
。大多数绘制函数支持名称值对参数。金宝app
Properties
Functions
得到 |
Query graphics object properties |
set |
设置图形对象属性 |
重置 |
将图形对象属性重置为默认值 |
Property Inspector | 开放物业检查员 |
Topics
此示例显示了如何在MATLAB®中创建,显示和修改图形对象。
图形objects are the visual components used by MATLAB®to display data graphically.
You can set and query property values or return them to their original (factory default) values.
Features Controlled by Graphics Objects
图形对象以直观和有意义的方式表示数据,例如这些对象的线图,图像,文本和组合。
几乎所有图形对象属性都有预定义的值,但是您可以定义默认属性值。
This example sets default values on more than one level in the hierarchy.
Default Values for Automatically Calculated Properties
When you create a graph, MATLAB sets certain property values appropriately for the particular graph.
How MATLAB Finds Default Values
全部graphics object properties have values built into MATLAB. You can also define your own default values.
Factory-Defined Property Values
绘制函数如果未将值指定为参数或默认值,则使用出厂定义的属性值。
了解DPI意识到的行为,以改善高分辨率系统上图形元素的外观。