https://bugs.kde.org/show_bug.cgi?id=502416
Bug ID: 502416 Summary: Text box dimensions are handled incorrectly - any changes to text should not affect the box size, and vice versa Classification: Applications Product: krita Version: 5.2.9 Platform: Microsoft Windows OS: Microsoft Windows Status: REPORTED Severity: normal Priority: NOR Component: Tool/Text Assignee: krita-bugs-n...@kde.org Reporter: jnewma...@gmx.com Target Milestone: --- When a text box is created, the program REQUIRES that a box be drawn to indicate the size and location of the desired box, but then it immediately discards all that information but the anchor/starting point, and recreates a text box that is defined by the contents of the box. This makes using the text box very difficult for text that gets modified. If the text box resizes every time text is entered or edited, then the box has to be continually repositioned if any alignment other than left is desired. If using Centered or Right alignment, then adding text changes the position of the right side of the box, thus changing the visual position of the text on the canvas, and requiring the text box be repositioned to place the text on the canvas in the visually correct position. Text boxes should maintain the drawn widths and paragraph styles - changing any font attributes or text within the box should not automatically change the dimensions of the text box unless it needs to be taller. And likewise, changing the dimensions of the text box should not automatically affect the font attributes of the text within the box (currently, if you widen the box, it changes the kerning of the text to fit the new box width). If it's desired to center a text title on a canvas, one should be able to draw a text box the width of the canvas, enter some text, center it, and have the box width remain the width of the canvas and have the anchor point of the text be set to the center of of the box. What actually happens is that as soon as the box is drawn full width, it is instantly resized to the effective width of the default placeholder text using the default/last font settings (font size, weight and kerning). That makes being required to draw a box in the first place a wasted effort, as the only thing used from that effort is the initial anchor point of the left edge of the drawn box. As such, the box has to then be repositioned to center the box within the canvas to get the desired effect. Even if the text is long enough to require multiple lines, 1) it does not autowrap (again does not respect the original size of the box drawn), and 2) it still resizes the text box to the widest line of text, meaning it has to be repositioned manually to the center it on the canvas again. And even after you've entered all your text and repositioned things as desired to get things visually centered, if you then edit the text, and the box width changes (as it likely will), you have to reposition the box again to recenter the text on the canvas. That is not how any of that should be handled. The text box should retain the dimensions that were initially drawn, and the text positioned accordingly within that box. If it is left "left aligned", and does not have enough characters to fill the box, then the text anchor point should be on the left edge of the box and there will just be empty space on the right. If the text is set to "right aligned", then the text anchor point should be at the right edge of the text box, and there will be empty space to the left of the text if there are not enough characters to fill the box. If the text is "aligned center", then the text anchor point should be set to the center of the text box, and if there are not enough characters to fill the box, then the empty space will be split evenly left and right. Text should be automaticaly wrapped to stay within the dimensions of the drawn text box so the dimensions of the text box are not disturbed. There should be no changes to the dimensions of the text box unless the text entered wraps and overflows past the bottom of the box - then just the bottom of the box should be extended to allow the text to be displayed. -- You are receiving this mail because: You are watching all bug changes.