diff --git a/src/apps/terminal/TermView.cpp b/src/apps/terminal/TermView.cpp index 16590e5fd7..610208e931 100644 --- a/src/apps/terminal/TermView.cpp +++ b/src/apps/terminal/TermView.cpp @@ -485,7 +485,7 @@ TermView::_LineOffset(int32 index) // convert view coordinates to terminal text buffer position -inline TermPos +TermPos TermView::_ConvertToTerminal(const BPoint &p) { return TermPos(p.x >= 0 ? (int32)p.x / fFontWidth : -1, _LineAt(p.y)); @@ -2626,14 +2626,14 @@ TermView::_CheckHighlightRegion(int32 row, int32 firstColumn, } continue; } - + if (row == highlight->End().y && firstColumn < highlight->End().x && lastColumn >= highlight->End().x) { // region starts in the highlight, but exceeds the end lastColumn = highlight->End().x - 1; return highlight; } - + TermPos pos(firstColumn, row); if (highlight->RangeContains(pos)) return highlight; diff --git a/src/apps/terminal/TermView.h b/src/apps/terminal/TermView.h index 5fc9c34482..a1ab24ed22 100644 --- a/src/apps/terminal/TermView.h +++ b/src/apps/terminal/TermView.h @@ -176,7 +176,7 @@ private: // point and text offset conversion inline int32 _LineAt(float y); inline float _LineOffset(int32 index); - inline TermPos _ConvertToTerminal(const BPoint& point); + TermPos _ConvertToTerminal(const BPoint& point); inline BPoint _ConvertFromTerminal(const TermPos& pos); inline void _InvalidateTextRect(int32 x1, int32 y1, diff --git a/src/apps/terminal/TermViewStates.cpp b/src/apps/terminal/TermViewStates.cpp index 8a85173bc5..9591983adf 100644 --- a/src/apps/terminal/TermViewStates.cpp +++ b/src/apps/terminal/TermViewStates.cpp @@ -17,6 +17,7 @@ #include "TermViewStates.h" #include +#include #include #include