text proportional scale
parent
2f8c3f1af9
commit
f602848cba
|
@ -392,7 +392,7 @@
|
|||
<h4>Text</h4>
|
||||
<div class="draginputs">
|
||||
<label class="draginput twocol textcontent hidden" data-title="Change Content">
|
||||
<input id="text" type="text"/>
|
||||
<input id="text" type="text" autocomplete="off"/>
|
||||
<span>Content</span>
|
||||
</label>
|
||||
<label>
|
||||
|
|
|
@ -112,7 +112,7 @@ svgedit.select.Selector.prototype.updateGripCursors = function(angle) {
|
|||
}
|
||||
var i = 0;
|
||||
for (var dir in selectorManager_.selectorGrips) {
|
||||
selectorManager_.selectorGrips[dir].setAttribute('style', ('cursor:' + dir_arr[i] + '-resize'));
|
||||
selectorManager_.selectorGrips[dir].style.cursor = dir_arr[i] + '-resize';
|
||||
i++;
|
||||
};
|
||||
};
|
||||
|
@ -128,6 +128,11 @@ svgedit.select.Selector.prototype.showGrips = function(show) {
|
|||
var elem = this.selectedElement;
|
||||
this.hasGrips = show;
|
||||
if(elem && show) {
|
||||
const isText = elem.tagName === "text";
|
||||
const grips = selectorManager_.selectorGrips;
|
||||
["n", "s", "e", "w"].forEach(dir => {
|
||||
grips[dir].style.display = isText ? "none" : "inline";
|
||||
});
|
||||
this.selectorGroup.appendChild(selectorManager_.selectorGripsGroup);
|
||||
this.updateGripCursors(svgedit.utilities.getRotationAngle(elem));
|
||||
}
|
||||
|
|
|
@ -1317,6 +1317,7 @@ var recalculateDimensions = this.recalculateDimensions = function(selected) {
|
|||
tlist.removeItem(k-2);
|
||||
tlist.appendItem(mt);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// If it still has a single [M] or [R][M], return null too (prevents BatchCommand from being returned).
|
||||
|
@ -2746,7 +2747,7 @@ var getMouseTarget = this.getMouseTarget = function(evt) {
|
|||
translateOrigin.setTranslate(-(left+tx),-(top+ty));
|
||||
}
|
||||
|
||||
if(evt.shiftKey) {
|
||||
if(evt.shiftKey || selected.tagName === "text") {
|
||||
if(sx == 1) sx = sy
|
||||
else sy = sx;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue