drawline segment as legend entry?

I am making some statistical process control charts as category plots and have added horizontal lines to represent spec limits, target values, standard deviations etc.
I have drawn horizontal lines across my graph at the appropriate locations using the drawline function.
Is it possible to add a snippet of the line (color, width, linestyle) as a legend entry in similar fashion to a trace symbol?

If this were a "normal" plot, I could have just made waves and added them to the plot at the appropriate levels.
The problem is that since I am using category plots, the horizontal line does not extend across the full width of the plot area.
I want the lines to extend to the furthest edges of the plot, if this can be accomplished with traces on category plots, that would be fine also.
Any other way to work around this issue would also be fine.
You can draw lines in an annotation (a legend is just a special sort of annotation) using escape codes. For instance:
\K(65535,0,0)\[0\x+99\L0700
\K(65535,0,65535)\[0             \L0700

draws two lines, the first one is red, the second magenta. The \[0 code saves the X position (among other things), \x+99 moves the X position and \L0700 draws a line from the saved position to the current position. The second line, instead of \x+99, uses a bunch of spaces to move the X position. It may be an easier way to move the distance you need.

To read more about these codes, if you're using Igor 7:
DisplayHelpTopic "Annotation Escape Codes"

If you're using Igor 6, look up the reference documentation for TextBox.

John Weeks
WaveMetrics, Inc.
support@wavemetrics.com
Thanks.
I have updated legends now using this scheme of adding lines via annotation escape codes.
I messed around with the spacing to get a nice match to the default legend values.
This is what the legend entry looks like it took to get it looking good:

\x+03\y+15\K(65535,0,0)\[0\x+35\L0703\y-15\x+03\K(0,0,0) text goes here



This is what it looks like from the command line:
TextBox/C/N=text1 "\\x+03\\y+15\\K(65535,0,0)\\[0\\x+35\\L0703\\y-15\\x+03\\K(0,0,0) text goes here";


Thanks.