Lines in Maya viewport

Hello, I made a custom locator/s in Maya that I would like to use eventually sometime, now my problem is i want to change the width of the line or the draw style(dashed line etc), I used glLineWidth() <- python but this is not changing the width of my line/s. :eek::eek::eek:

when I put this as a child of the beginGL for the view, all the lines become as thick as the value in the glLineWidth() …

I am new to the Maya Python API and I apologize in advance if this seem to be too simple a question to ask.

My background is a CG generalist but I find myself doing more technical stuff in the past years. Thanks

Are you pushing/popping glAttrib bits?
e.g.


view.beginGL(); 
glPushAttrib( GL_CURRENT_BIT ); 
glPushAttrib( GL_ALL_ATTRIB_BITS ); 

... # Draw code

glPopAttrib();
glPopAttrib();
view.endGL(); 

Oh, thank goodness. a reply!

Yes,sir I am…do these have implications with the draw codes? I am just modifying the footPrintNode in the samples library as a start. Learning openGL with Maya Python API is harder than I think

Does the original footprint code work fine unmodified? If so, then what exactly are your Draw() method changes?

Thanks, I finally figured out how that works!