Merge pull request #833 from luco5826/master

Highlight position in small cursor mode too
presentation
andreasb242 7 years ago committed by GitHub
commit 3632393690
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 17
      src/gui/Cursor.cpp

@ -327,7 +327,7 @@ GdkCursor* Cursor::createHighlighterOrPenCursor(int size, double alpha)
int height = size;
int width = size;
if (big)
if (big || highlightPosition)
{
height = width = 100;
}
@ -377,20 +377,21 @@ GdkCursor* Cursor::createHighlighterOrPenCursor(int size, double alpha)
cairo_set_source_rgb(cr, 0, 0, 0);
cairo_stroke(cr);
if(highlightPosition)
cairo_fill_preserve(cr);
}
if(highlightPosition)
{
// A yellow transparent circle with no border
cairo_set_line_width(cr, 0);
cairo_set_source_rgba(cr, 255, 255, 0, 0.5);
cairo_arc(cr, centerX, centerY, 45, 0, 2 * 3.1415);
}
cairo_fill_preserve(cr);
cairo_set_source_rgb(cr, 0, 0, 0);
cairo_stroke(cr);
cairo_fill_preserve(cr);
cairo_set_source_rgb(cr, 0, 0, 0);
cairo_stroke(cr);
}
}
cairo_set_source_rgba(cr, r, g, b, alpha);
// Correct the offset of the coloured dot for big-cursor mode

Loading…
Cancel
Save