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

Long lines chopped at window/terminal width #377

Closed
kennylevinsen opened this issue Sep 14, 2014 · 4 comments
Closed

Long lines chopped at window/terminal width #377

kennylevinsen opened this issue Sep 14, 2014 · 4 comments

Comments

@kennylevinsen
Copy link
Contributor

kennylevinsen commented Sep 14, 2014

There is currently no support for horizontal scrolling or word wrapping, causing the extra content to be chopped off. Word wrapping (In my opinion highest priority!) and horizontal scrolling needs to be implemented.

@quarnster
Copy link
Member

Should be quite easy to fix due to the terminal's fixed font width

@kennylevinsen
Copy link
Contributor Author

For termbox, indeed (which is my preferred frontend), but I believe it might be more tricky for qml? It exhibits the same issues when I tested it, and unless qml provides assistive mechanism, then non-monospace fonts could make this a funky issue indeed.

@quarnster
Copy link
Member

QML should be able to do word wrap and scrolling trivially where the immediate quick-fix for both would be:

diff --git a/frontend/qml/LimeView.qml b/frontend/qml/LimeView.qml
index 368095a..5da6545 100644
--- a/frontend/qml/LimeView.qml
+++ b/frontend/qml/LimeView.qml
@@ -51,6 +51,8 @@ Item {
             text: line.text
             textFormat: TextEdit.RichText
             color: "white"
+            width: parent.parent.width
+            wrapMode: "WordWrap"
         }
         states: [
             State {

and

diff --git a/frontend/qml/LimeView.qml b/frontend/qml/LimeView.qml
index 368095a..9bfac76 100644
--- a/frontend/qml/LimeView.qml
+++ b/frontend/qml/LimeView.qml
@@ -148,7 +148,7 @@ Item {
                 }
             }
             onWheel: {
-                view.flick(0, wheel.angleDelta.y*100);
+                view.flick(wheel.angleDelta.x*100, wheel.angleDelta.y*100);
                 wheel.accepted = true;
             }
         }

But it needs logic for a horizontal scrollbar + minimap and others.

@quarnster quarnster added this to the v0.1 milestone Apr 17, 2015
@quarnster quarnster changed the title Long lines chopped at window/terminal width Long lines chopped at window/terminal width [$5] Sep 1, 2015
@quarnster quarnster changed the title Long lines chopped at window/terminal width [$5] Long lines chopped at window/terminal width Sep 2, 2015
@quarnster quarnster removed the bounty label Sep 2, 2015
@zoli zoli removed the frontend label May 22, 2016
@zoli
Copy link
Member

zoli commented Jun 1, 2016

Moved to frontend repos limetext/lime-termbox#14, limetext/lime-qml#30.

@zoli zoli closed this as completed Jun 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants