simpleclub / math_keyboard

Math expression editing using an on-screen software keyboard or physical keyboard input in a typeset input field in Flutter.
https://simpleclub.github.io/math_keyboard
BSD 3-Clause "New" or "Revised" License
133 stars 49 forks source link

A RenderLine overflowed by 1.5 pixels on the right. #32

Open Kumah1 opened 2 years ago

Kumah1 commented 2 years ago

I am using math_keyboard in my app, when it opens and i want to navigate to more keys like square root and the like the log() give an error like this

======== Exception caught by rendering library ===================================================== The following assertion was thrown during layout: A RenderLine overflowed by 1.5 pixels on the right.

The relevant error-causing widget was: MaterialApp MaterialApp:file:///D:/PROGRAMMING/AndroidStudioProjects/learnmath/lib/src/app.dart:28:16 The edge of the RenderLine that is overflowing has been marked in the rendering with a yellow and black striped pattern. This is usually caused by the contents being too big for the RenderLine.

Consider applying a flex factor (e.g. using an Expanded widget) to force the children of the RenderLine to fit within the available space instead of being sized to their natural size. This is considered an error condition because it indicates that there is content that cannot be seen. If the content is legitimately bigger than the available space, consider clipping it with a ClipRect widget before putting it in the flex, or using a scrollable container rather than a Flex, like a ListView.

So this means the log() needs more paint. I am debugging on infinix Hot S3 ( x573) to be precise.

Please how should I solve this?

Screenshots

math_keyboard

github-actions[bot] commented 2 years ago

Hi 👋🏽 Thank you for opening your first issue with simpleclub/math_keyboard ❤

You can expect triage from us soon 🙂 In the meantime, you can try to search for similar issues in our issue database.

creativecreatorormaybenot commented 2 years ago

@edhom looks like we did not consider screen sizes this small. I think the easiest and most flexible fix would be allowing to pass the font size for the symbols or decreasing the size for the functions in general if we can guarantee that even smaller screen sizes are not sensible.

Kumah1 commented 2 years ago

please I need the fix badly

edhom commented 2 years ago

@creativecreatorormaybenot Yes we can do that👍 @Kumah1 I won't get to this any time soon, so if it's urgent, feel free to open a PR!

Kumah1 commented 2 years ago

Please I don't understand what you mean by PR.

creativecreatorormaybenot commented 2 years ago

@Kumah1 here you can learn about what a PR (pull request) is:

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests