Print using Stand Output in MEL

Viewed 195

In Maya, with Python, I can write to the Command Response Window (I think it's called that - the single line window at the bottom right of the screen):

import sys

def console_it(s):
  sys.stdout.write(s)

console_it("Hello world")

What's the equivalent using MEL?

The following just prints to the Script editor History Window - which is not what I'm after.

global proc console_it(string $s)
{
    print($s);
}
1 Answers

I can't find a direct equivalent for sys.stdout.write(s).

But you could try a warning command:

global proc console_it(string $s)
{
    warning $s;
}

console_it("Hello World")

P.S.

Or a trace command, as @robthebloke suggested.

Related