Home > ISCH_PrimitiveText > getState_Content
ISCH_PrimitiveText.getState_Content() method
获取属性状态:文本内容
签名
typescript
function getState_Content(): string;1
返回值
string
文本内容
示例
javascript
// 1. 创建一个测试文本(SCH 坐标单位 10mil,第 3 参是文字内容)
const text = await eda.sch_PrimitiveText.create(400, 300, '嘉立创示例_标题');
// 2. 读取文字内容
const content = text.getState_Content();
// 3. 清理测试图元(查询类案例不留测试对象)
await eda.sch_PrimitiveText.delete([text.getState_PrimitiveId()]);
console.log('content:', content);1
2
3
4
5
6
7
8
9
10
2
3
4
5
6
7
8
9
10