line

Determine which side of a line a point lies.

Hey guys, I've got a line (x1,y1) and (x2, y2). I'd like to see if point (x3, y3) lies to the "left" or "right" of said line. How would I do so? ...

Calculating intersect point of 2 lat/lng line segments on earth

Hello, i've been trying multiple functions including 2D ones to try to get this somewhat working, but no luck yet... I have 2 line segments of latlng endpoints on earth, and i want to know if and where the 2 lines intersect. I'm currently working with this which a physics major says should be doing the job for a 2d plane but its not. i...

How to compile bada gcc toolchain from command line?

Hello I want to develop a helloworld application but want to compile it using Command line not by BADA IDE.Could any body help me with it. Thanks ...

OpenGL Line Width

In my OpenGL app, it won't let me draw a line greater then ten pixels wide. Is there a way to make it draw more than ten pixels? void OGL_Renderer::drawLine(int x, int y, int x2, int y2, int r, int g, int b, int a, int line_width) { glColor4ub(r, g, b, a); glLineWidth((GLfloat)line_width); glBegin(GL_LINES); glVertex2i(x, y); glVe...

C read file line by line

I wrote this function to read a line from a file: const char *readLine(FILE *file) { if (file == NULL) { printf("Error: file pointer is null."); exit(1); } int maximumLineLength = 128; char *lineBuffer = (char *)malloc(sizeof(char) * maximumLineLength); if (lineBuffer == NULL) { printf("Err...

Get rid of the line under TabWidget

I've got simple tab activity with next layout: <TabWidget android:id="@android:id/tabs" android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="#ffffff00" /> <FrameLayout android:id="@android:id/tabcontent" android:layout_width="fill_pa...

How to draw a line on an image in matlab?

I have two points lets say: P(x,y) [point lies at the top of image] P'(x',y') [point lies at bottom of image] Now i want to draw a line betwen these two points....and the line should appear on image means should be visible. how to do this???? ...

Build and run FlexUnit from the command line

I am building an app using ActionScript3 with Flash Builder 4 as my IDE. The IDE supports a unit testing framework called "FlexUnit". I can build and run tests within the IDE, no problem. After much pain and suffering I figured out how to build the unit tests as a swf from the command line. I can point a browser or flash player at ...

file_put_contents, file_append and line breaks

I'm writing a PHP script that adds numbers into a text file. I want to have one number on every line, like this: 1 5 8 12 If I use file_put_contents($filename, $commentnumber, FILE_APPEND), the result looks like: 15812 If I add a line break like file_put_contents($filename, $commentnumber . "\n", FILE_APPEND), spaces are added afte...

PHP script to grab entire line

Hi there, Thank you for taking the time to read this and I will appreciate every single response no mater the quality of content. :) I'm trying to create a php script which searches a text file for specific text. A person types in the specific text within a HTML form and the php script should search for that specific text within the te...

Drawing text on/on top of line in WPF

Hi guys (and girls); I was wondering if it was possible to do either in WPF: I guess the main problem here that I can't embed a textblock in a line in XAML, which is something I'm use to doing. Does anyone have any idea of how I can tackle this problem? EDIT: It would also have to handle diagonal text. ...

Partition line into equal parts

Hello, This is a geometry question. I have a line between two points A and B and want separate it into k equal parts. I need the coordinates of the points that partition the line between A and B. Any help is highly appreciated. Thanks a lot! ...

how do i overlay a "line chart" on a "point chart" using asp.net charting toolkit?

I currently have a point chart using the asp.net charting toolkit, but would like to place a line of best fit on the same chart. Assuming that I know how to calculate the equation for the line (y=mx+b), how would I overlay this in the same graph? ...

Best tool to remove dos line ends and join line back up again

I have a csv file into which has crept some ^M dos line ends, and I want to get rid of them, as well as 16 spaces and 3 tabs which follow. Like, I have to merge that line with the next one down. Heres an offending record and a good one as a sample of what I mean: "Mary had a ^M little lamb", "Nursery Rhyme", 1878 "Ma...

erase lines after drawing them in PyGTK- Cairo

hi, I want to ask how can I erase a line witch I've drawn by using the pyGTK I used:cairo library cr = widget.window.cairo_create() cr.move_to(x, y) cr.line_to(x1, y1) cr.stroke() I want to delete this line after drawing it on screen ...

Selecting and printing specific rows of text file

I have a very large (~8 gb) text file that has very long lines. I would like to pull out lines in selected ranges of this file and put them in another text file. In fact my question is very similar to this and this but I keep getting stuck when I try to select a range of lines instead of a single line. So far this is the only approa...

what do you call this gray line thing in html

hi what do you call this "gray line" in html, where you can use like a separator? Thanks ...

Draw a Connection Line in RaphaelJS

How would I go about drawing a connection line in Raphael where the mousedown initiates the starting point of the line, the mousemove moves the end point without moving the start point and the mouseup leaves it as it is? ...

Testing if a line has a point within a triangle

How can I test whether a line has a point that lies within (not on the edge of) a triangle. (All in 2D). Currently I'm thinking I'll do this: Define the line, and each side of the triangle as Ax+By+C=0, and have an xrange. Check if the line intersects any of the lines of the triangle. If it does, check that this is NOT at the end of t...

html5 canvas drawing multicolred lines

I am trying to draw two parallel lines on the canvas, but seems like properties of the latter overwrites the former. Please suggest what could be wrong : <html> <head> <script type="application/javascript"> function draw() { var canvas = document.getElementById('canvas'); var ctx = canvas.getContext('2d'); // draw a 10 pix...