Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 1,000 results for
drawline
- Page 1
Re: drawline
Programming
Software Development
16 Years Ago
by Nemoticchigga
… = gcnew Pen(Color::Yellow, 3); grfx->
DrawLine
(myPen, this->Map->Width/2, this…this->Map->Height/2); grfx->
DrawLine
(myPen, this->Map->Width/2, this…Map->Height/2 - 10); grfx->
DrawLine
(myPen, this->Map->Width/2, this…this->Map->Height/2); grfx->
DrawLine
(myPen, this->Map->Width/2, this…
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by javadumbass
…); for(int i = 0; i < al.size(); i++){ g.
drawLine
(drawLines[i][0],drawLines[i][1],drawLines[i][2],drawLines…
usiing DrawLine method in .net to draw a free-draw line - horrible when line is thick
Programming
Software Development
15 Years Ago
by unclepauly
hello, i am using the Graphics.
DrawLine
method in C# and this is fine for thin lines … == 0 && prevPoint.Y == 0) { prevPoint = thisPoint; return; } g.
DrawLine
(myPen, thisPoint.X, thisPoint.Y, prevPoint.X, prevPoint.Y); prevPoint…
Re: g.drawLine(x1, y1, x2, y2)
Programming
Software Development
12 Years Ago
by JamesCherrill
….oracle.com/javase/7/docs/api/ for
drawLine
it says > public abstract void
drawLine
(int x1, > int y1, > int…
Graphics.DrawLine method does not work properly with thick line and transparent color
Programming
Software Development
14 Years Ago
by jayantpaliwal
… move mouse up and down. //pen.EndCap = LineCap.Round; g.
DrawLine
(pen, startPos, curPos); g.Dispose(); startPos = curPos; } } private void frmTest_MouseUp…
g.drawLine(x1, y1, x2, y2)
Programming
Software Development
12 Years Ago
by gelmi
Good Day i just wanted to ask what does (x1, y1, x2, y2) in g.
drawLine
in creating a line in java applet.. thanks in advance
Re: g.drawLine(x1, y1, x2, y2)
Programming
Software Development
12 Years Ago
by gelmi
oops sorry.. what does x1, y1, x2 y2 means? in g.
drawLine
(x1, y1, x2, y2)
drawline
Programming
Software Development
16 Years Ago
by Nemoticchigga
How do you draw on an image in visual studio 2005 and get it to stay? Ive can get it to draw, but it flickers on resize and disappears when the resize is done. Any ideas?
Re: drawline
Programming
Software Development
16 Years Ago
by Nick Evan
Could you post the code that you're using?
Re: looping the drawLine() method
Programming
Software Development
15 Years Ago
by santiagozky
…=100; for(int i=0;i<100;i++){ g.
drawLine
(x1,y1,x2,y2); //x1 does not change y1=y1…
Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by javadumbass
I need to create a program where in you would draw a line, just like the paint application, but if you drag it, the lines you created would be deleted.It also displays the(x,y) where your mouse point at in the screen. I'm starting on nothing.So anyone who can help me? thanks!
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by JamesCherrill
Start with some kind of frame (eg JFrame), add a MouseListener, try something simple (eg draw a small rectangle wherever the mouse was clicked - you will need to override paintComponent(...) ) and work up from there. As you go you will (a) learn a lot and (b) discover exactly what additional knowledge/skill you need to complete the task. You can …
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by NormR1
Also while your are developing the code as James mentioned, add some print statements in the listeners to show the x,y values where the mouse was clicked and moved to. There are different points of reference: to the screen and to the component for example.
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by javadumbass
do you have he exact codes needed. I don't now where to start it.
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by JamesCherrill
OK, well done, that looks like a decent start. But when you say "it draws the wrong lines" that doesn't help. You need to think very clearly about what you expect to happen, what actually happens, and why they are different. Use this simple but powerful way to debug your code: Put System.out.println(...) statements in many places in your …
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by Ezzaral
[B]>> OK, well done, that looks like a decent start.[/B] It's a decent start copying this program: [url]http://www.engineeringserver.com/forum/java+paint+application-t2342.0.html[/url] Not much of a start showing any effort though. Perhaps the OP will post some more specific questions indicating that he understands the code he posted and …
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by JamesCherrill
Ah. I fell for that one, didn't I? Seems I need to turn up my scepticism filter a notch or two. Good choice of name, dumbass. I guess you learned a lot from that.
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by Ezzaral
He still has yet to get it working for his requirements, so perhaps there is some learning left to be had. Let's see if any effort is forthcoming.
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by javadumbass
sorry, used the wrong term. What I mean was instead of the lines connecting each other, it goes the other way.it just creates the lines,but does not connect. i also saw the program in this link:[url]http://www.engineeringserver.com/for...n-t2342.0.html[/url] but don't know where and how to insert it in my program since I'm a beginner in java.
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by NormR1
[QUOTE]it just creates the lines,but does not connect.[/QUOTE] Does that mean that the ending x,y point for one line does NOT equal the beginning x,y point for another line? Look in the code to see why the end of one line is not used for the beginning of the next line?
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by Ezzaral
You should start by figuring out how it works. Then you can figure out how to adapt it. So far you have only copied and pasted someone else's program here and demonstrated no effort whatsoever of your own.
Re: Drawline using mouse listener etc.
Programming
Software Development
14 Years Ago
by javadumbass
really on rush. But thanks to your help! :))
Re: usiing DrawLine method in .net to draw a free-draw line - horrible when line is thick
Programming
Software Development
15 Years Ago
by ddanbe
Set the SmootingMode of the Graphics object to AntiAlias or HighQuality. Like so: [B]g.SmootingMode = System.Drawing.Drawing2D.SmootingMode.HighQuality;[/B]
Re: usiing DrawLine method in .net to draw a free-draw line - horrible when line is thick
Programming
Software Development
15 Years Ago
by unclepauly
thanks i have tried this but the problem is the same. i have just been through all the SmoothingModes with the same result. any other ideas ?
Re: usiing DrawLine method in .net to draw a free-draw line - horrible when line is thick
Programming
Software Development
15 Years Ago
by unclepauly
the solution is: Pen.SetLineCap(LineCap.Round,LineCap.Round,DashCap.Round); for anyone else having this problem.
Re: usiing DrawLine method in .net to draw a free-draw line - horrible when line is thick
Programming
Software Development
15 Years Ago
by ddanbe
Still have to investigate this, but this might be related to the problem I have in this thread [url]http://www.daniweb.com/forums/thread201807.html[/url]. Thanks for the tip!
Re: usiing DrawLine method in .net to draw a free-draw line - horrible when line is thick
Programming
Software Development
14 Years Ago
by jayantpaliwal
[QUOTE=ddanbe;1091379]Still have to investigate this, but this might be related to the problem I have in this thread [url]http://www.daniweb.com/forums/thread201807.html[/url]. Thanks for the tip![/QUOTE] Hello All, I am struggling with the same issue. Setting pen.StartCap = LineCap.Round; and pen.EndCap = LineCap.Round; will only works if …
Re: Graphics.DrawLine method does not work properly with thick line and transparent color
Programming
Software Development
14 Years Ago
by lxXTaCoXxl
Sorry that I can't be of any help, however you should really check the argument information on MSDN if you haven't already. Those often help out in large quantities.
Re: g.drawLine(x1, y1, x2, y2)
Programming
Software Development
12 Years Ago
by nmaillet
I don't get what you're asking...
generation of random cars in an applet
Programming
Software Development
15 Years Ago
by nitang
…, 200, 270, 220); //Devider2 g.
drawLine
(270, 320, 270, 340); g.
drawLine
(270, 350, 270, 370); g.
drawLine
(270, 380, 270, 400); g…, 270, 220, 270); //Devider4 g.
drawLine
(320, 270, 340, 270); g.
drawLine
(350, 270, 370, 270); g.
drawLine
(380, 270, 400, 270); g…
1
2
3
17
Next
Last
Search
Search
Forums
Forum Index
Hardware/Software
Recommended Topics
Programming
Recommended Topics
Digital Media
Recommended Topics
Community Center
Recommended Topics
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Top Members
Meet People
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
Backlink Auditor
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2025 DaniWeb® LLC