class FuncStatus;
class Intl;
class Inset;
+class Menu;
class ParIterator;
class ParagraphMetrics;
class Point;
/// Scrollbar Parameters.
struct ScrollbarParameters
{
- void reset(int h = 0, int p = 0, int l = 0)
- {
- height = h;
- position = p;
- lineScrollHeight = l;
- }
-
- /// Total document height in pixels.
- int height;
+ /// Minimum scrollbar position in pixels.
+ int min;
+ /// Maximum scrollbar position in pixels.
+ int max;
/// Current position in the document in pixels.
int position;
/// Line-scroll amount in pixels.
- int lineScrollHeight;
+ int single_step;
+ /// Page-scroll amount in pixels.
+ int page_step;
};
/// Screen view of a Buffer.
ScrollbarParameters const & scrollbarParameters() const;
/// \return Tool tip for the given position.
docstring toolTip(int x, int y) const;
+ /// \return the context menu for the given position.
+ docstring contextMenu(int x, int y) const;
/// Save the current position as bookmark.
/// if idx == 0, save to temp_bookmark
/// set the cursor based on the given TeX source row.
void setCursorFromRow(int row);
- /// Ensure the cursor is visible.
- /// This method will automatically scroll and update the BufferView and updated
+ /// Ensure that the BufferView cursor is visible.
+ /// This method will automatically scroll and update the BufferView
/// if needed.
void showCursor();
+ /// Ensure the passed cursor \p dit is visible.
+ /// This method will automatically scroll and update the BufferView
+ /// if needed.
+ void showCursor(DocIterator const & dit);
+ /// LFUN_SCROLL Helper.
+ void lfunScroll(FuncRequest const & cmd);
/// scroll down document by the given number of pixels.
void scrollDown(int pixels);
/// scroll up document by the given number of pixels.