Skip to content

Commit

Permalink
Merge pull request #3035 from yangcaimu/master
Browse files Browse the repository at this point in the history
Fix BalloonMarker's text position calculation, consider insets
  • Loading branch information
liuxuan30 authored Jan 15, 2018
2 parents 0011c35 + ea00ed0 commit ba40ab4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ChartsDemo/Swift/Components/BalloonMarker.swift
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,9 @@ public class BalloonMarker: MarkerImage {
y: rect.origin.y))
context.fillPath()

rect.origin.x += self.insets.left
rect.origin.y += self.insets.top
rect.size.width -= self.insets.left + self.insets.right
rect.size.height -= self.insets.top + self.insets.bottom

UIGraphicsPushContext(context)
Expand Down

0 comments on commit ba40ab4

Please sign in to comment.