Commit 2ecf75b0 authored by rockyl's avatar rockyl

完善文本逻辑

parent 901b139a
......@@ -258,11 +258,12 @@ async function execute$1(psdFile, options) {
const {RunLengthArray} = fontInfo.engineData.EngineDict.StyleRun;
properties.text = fontInfo.textValue;
properties.size = styles.sizes()[0] / 2;
let [r, g, b, a] = fontInfo.colors()[0];
properties.color = `rgba(${r}, ${g}, ${b}, ${a / 255})`;
properties.textflow = {
properties.fillColor = `rgba(${r}, ${g}, ${b}, ${a / 255})`;
/*properties.textflow = {
fonts, styles, RunLengthArray,
};
};*/
viewNode.type = 'label';
} else if (solidColor) {
const {r, g, b} = solidColor();
......
This diff is collapsed.
......@@ -264,11 +264,12 @@ async function execute$1(psdFile, options) {
const {RunLengthArray} = fontInfo.engineData.EngineDict.StyleRun;
properties.text = fontInfo.textValue;
properties.size = styles.sizes()[0] / 2;
let [r, g, b, a] = fontInfo.colors()[0];
properties.color = `rgba(${r}, ${g}, ${b}, ${a / 255})`;
properties.textflow = {
properties.fillColor = `rgba(${r}, ${g}, ${b}, ${a / 255})`;
/*properties.textflow = {
fonts, styles, RunLengthArray,
};
};*/
viewNode.type = 'label';
} else if (solidColor) {
const {r, g, b} = solidColor();
......
This diff is collapsed.
......@@ -264,11 +264,12 @@
const {RunLengthArray} = fontInfo.engineData.EngineDict.StyleRun;
properties.text = fontInfo.textValue;
properties.size = styles.sizes()[0] / 2;
let [r, g, b, a] = fontInfo.colors()[0];
properties.color = `rgba(${r}, ${g}, ${b}, ${a / 255})`;
properties.textflow = {
properties.fillColor = `rgba(${r}, ${g}, ${b}, ${a / 255})`;
/*properties.textflow = {
fonts, styles, RunLengthArray,
};
};*/
viewNode.type = 'label';
} else if (solidColor) {
const {r, g, b} = solidColor();
......
This diff is collapsed.
......@@ -51,11 +51,12 @@ export async function execute(psdFile, options) {
const {RunLengthArray} = fontInfo.engineData.EngineDict.StyleRun;
properties.text = fontInfo.textValue;
properties.size = styles.sizes()[0] / 2;
let [r, g, b, a] = fontInfo.colors()[0];
properties.color = `rgba(${r}, ${g}, ${b}, ${a / 255})`;
properties.textflow = {
properties.fillColor = `rgba(${r}, ${g}, ${b}, ${a / 255})`;
/*properties.textflow = {
fonts, styles, RunLengthArray,
};
};*/
viewNode.type = 'label';
} else if (solidColor) {
const {r, g, b} = solidColor();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment