rmp icon indicating copy to clipboard operation
rmp copied to clipboard

增加文本和车站名压扁功能

Open Thariven opened this issue 7 months ago • 6 comments

建议增加一个“车站名压扁”和“文本压扁”的功能,这在某些拥挤区域很有用(如下图) Image (图中“木樨地”中文名、“复兴门“中英文名、”达官营“英文名等均有不同程度压扁)

Thariven avatar Jun 05 '25 13:06 Thariven

嗨,感谢提出建议!我们将会考虑此功能 :)


cc @langonginc 如果你觉得有必要增加的话,我们应该可以利用transform里的scale效果

https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/Attribute/transform#scale

当然,也可以指出不合理的理由关闭即可 :)

thekingofcity avatar Jun 06 '25 03:06 thekingofcity

@thekingofcity 此方案不利于新手操作使用。建议为文本组件增加“长度/宽度比例”功能。建议使用1为原比例,0-1为在单轴上压缩,1以上为放大,0以下为镜像压缩/放大(同时填补了无法镜像文字的问题)

NotSparkle avatar Aug 15 '25 10:08 NotSparkle

可以这样(也可以写一个“帮助”放旁边),谢谢

Thariven avatar Aug 15 '25 14:08 Thariven

https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/Attribute/textLength

This is a better option I believe.

thekingofcity avatar Sep 01 '25 14:09 thekingofcity

https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/Attribute/textLength

This is a better option I believe.

It doesn't appear to be scaling but rather arranging the letters more closely together.

langonginc avatar Sep 04 '25 12:09 langonginc

https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/Attribute/textLength This is a better option I believe.

It doesn't appear to be scaling but rather arranging the letters more closely together.

Sorry, another one is also needed to achieve the letter scale.

https://developer.mozilla.org/en-US/docs/Web/SVG/Reference/Attribute/lengthAdjust

thekingofcity avatar Sep 04 '25 13:09 thekingofcity