Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Word order gets meesed up and curser location problem #7267

Open
mehranj73 opened this issue Jan 3, 2025 · 1 comment
Open

Word order gets meesed up and curser location problem #7267

mehranj73 opened this issue Jan 3, 2025 · 1 comment
Labels
a:text Text rendering, fonts, Text input (mS,bF) bug Something isn't working need triaging Issue that the owner of the area still need to triage

Comments

@mehranj73
Copy link

Bug Description

While I write Persian in LineEdit, the cursor location gets weird and when I select a part of the text with mouse, the word order of my text gets messed up.
Untitled

Reproducible Code (if applicable)

import {LineEdit, Button, VerticalBox } from "std-widgets.slint";

export struct Person {
    age: int,
    name: string,

}



export component AppWindow inherits Window {
    out property <Person> result;
    callback divide-income(string);
    callback get-person(Person);



    width: 1000px;

    VerticalLayout {

        HorizontalLayout {
            padding: 10px;
            LineEdit {
                placeholder-text: "اسم";
                horizontal-alignment: right;


            }

            number := LineEdit {
                placeholder-text: "شماره پرونده";
                horizontal-alignment: right;

            }

        }

        HorizontalLayout {
            spacing: 10px;
            padding: 10px;

            LineEdit {
                placeholder-text: "کد شعبه";
                horizontal-alignment: right;

            }

            LineEdit {
                placeholder-text: "کد نوع تسهیلات";
                horizontal-alignment: right;

            }

            LineEdit {
                placeholder-text: "کد مشتری";
                horizontal-alignment: right;

            }

            LineEdit {
                placeholder-text: "شماره قرارداد";
                horizontal-alignment: right;

            }
        }

        HorizontalLayout {
            padding: 15px;
            LineEdit {
                placeholder-text: "مبلغ";
                horizontal-alignment: right;

            }
        }

        HorizontalLayout {
            spacing: 10px;
            padding: 20px;

            LineEdit {
                placeholder-text: "نوع قرارداد";
                horizontal-alignment: right;

            }

            LineEdit {
                placeholder-text: "کد اعتباری";
                horizontal-alignment: right;

            }

            LineEdit {
                placeholder-text: "نرخ";
                horizontal-alignment: right;

            }
        }

        HorizontalLayout {
            LineEdit {
                placeholder-text: "سال پرداخت";
                horizontal-alignment: right;

            }

            LineEdit {
                placeholder-text: "ماه پرداخت";
                horizontal-alignment: right;

            }

            LineEdit {
                placeholder-text: "مذت باز پرداخت";
                horizontal-alignment: right;

            }
        }

        Button {
            text: "ایجاد";
            clicked => {
                divide-income(number.text);
                result = {name: number.text, age: 5};

                get-person(result);
            }
        }
    }
}

Environment Details

  • Slint Version: 1.9.1
  • Platform/OS: Windows 10
  • Programming Language: Rust
  • Backend/Renderer: I don't know what this is.

Product Impact

No response

@mehranj73 mehranj73 added bug Something isn't working need triaging Issue that the owner of the area still need to triage labels Jan 3, 2025
@mehranj73
Copy link
Author

I cannot also copy paste into line text when my windows' keyboard is in Persian.

@ogoffart ogoffart added the a:text Text rendering, fonts, Text input (mS,bF) label Jan 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a:text Text rendering, fonts, Text input (mS,bF) bug Something isn't working need triaging Issue that the owner of the area still need to triage
Projects
None yet
Development

No branches or pull requests

2 participants