Matrix transformation

I would like to place the matrix in the top left corner of the window, with the x axis positive left to right and the y axis positive top to down; and each pixel would value 1, I mean for a resolution of 1024x768 if I draw a line with vertexes (0,0,0) and (1024,0,0) I would get a top border for the window

You can use glOrtho or gluOrtho2D for that:

gluOrtho2D(0, width, height, 0)

I used glOrtho but when i draw a quad nothing appears

It could be that your quad lies behind the far clipping plane or in front of the near clipping plane. Or you could have culling enabled and specify the vertices in the wrong order.