Created
March 19, 2015 00:28
-
-
Save lettergram/fc8ffc85d68c36d7646f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void OpenBKZ::on_graphicsView_rubberBandChanged(const QRect &viewportRect, const QPointF &fromScenePoint, const QPointF &toScenePoint){ | |
/** | |
* fromScenePoint.y() & fromScenePoint.x() are zero upon release, | |
* I.E when the user has finished their highlighting. | |
*/ | |
if(fromScenePoint.y() != 0 && toScenePoint.y() != 0){ | |
this->start = toScenePoint.y(); | |
this->end = fromScenePoint.y(); | |
return; | |
} | |
if(this->start/(this->fontsize + 3) == this->end/(this->fontsize + 3)) | |
searchWord(); | |
else | |
saveHighlightedSection(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment