Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

hwo to resize line  RSS feed

 
pqds peter
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i had draw line on the view(mvc str)
and when i resize the line by mouse
public void mothname(Point last)
{
line.x2 = last.x - position.x;
line.y2 = last.y - position.y;
}//this position is the line's position
if i resize the end_point the application is right
but when i resize the start_point
the line not get the right resize
the start point is the mouse_point and the line's end is the mouse_point too!
how can i write it right!
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!