Author |
Message |
Gadiuz
|
Posted: Mon Apr 28, 2008 6:53 pm Post subject: Drawing program help :D |
|
|
I've been working on this program for fun during my free time in my computer science class and hit a snag. When I try to draw using the equivalent to a pen tool the animation is to slow to keep up and i get blank spaces. help please
Description: |
The section for my pen tool |
|
![](http://compsci.ca/v3/pafiledb/images/icons/clip.gif) Download |
Filename: |
fdsfs.t |
Filesize: |
256 Bytes |
Downloaded: |
118 Time(s) |
|
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
cavetroll
![](http://compsci.ca/v3/uploads/user_avatars/9161761347fd5efa4f4b5.jpg)
|
Posted: Mon Apr 28, 2008 8:15 pm Post subject: Re: Drawing program help :D |
|
|
Why are you updating only a specific area? Just call regular View.Update instead View.UpdateArea (40, 400, 1000, 0) this will update the whole screen. As for the slow animation, I don't think you can do anything about that. Just move the mouse slower.
|
|
|
|
|
![](images/spacer.gif) |
gitoxa
![](http://compsci.ca/v3/uploads/user_avatars/125344263047f801d546bcb.jpg)
|
Posted: Mon Apr 28, 2008 8:18 pm Post subject: Re: Drawing program help :D |
|
|
He's probably updating just the area because the code he posted is only a sample. In a paint program, you generally aren't allowed to draw on your gui.
|
|
|
|
|
![](images/spacer.gif) |
cavetroll
![](http://compsci.ca/v3/uploads/user_avatars/9161761347fd5efa4f4b5.jpg)
|
Posted: Mon Apr 28, 2008 8:26 pm Post subject: Re: Drawing program help :D |
|
|
My bad, that makes sense. I guess my post isn't much use then.
But I can't help but wonder why he asked about white spaces if he was intending to not display circles in the white spaces. Also when you click out of the window the circles get updated so it would make more sense to draw a white rectangle and update the whole screen. Either that or check where the circle is and don't allow drawing in specific areas.
|
|
|
|
|
![](images/spacer.gif) |
Gadiuz
|
Posted: Tue Apr 29, 2008 7:51 am Post subject: Re: Drawing program help :D |
|
|
Ya I was going to try to put in a tool bar for different colors, and things like drawing boxes and lines. But I decided to try to just get this to work first. I dont even know if I make the box and line tools. ( I barely know any turing )
|
|
|
|
|
![](images/spacer.gif) |
|