![](https://secure.gravatar.com/avatar/02a711d78d02355347d6cff73fda2572.jpg?s=120&d=mm&r=g)
11 May
2010
11 May
'10
1:03 p.m.
numeric r, g, b ;
r := uniformdeviate 1 ; g := uniformdeviate 1 ; b := uniformdeviate 1 ;
textext("\colored[r=" & r & ",g=" & g & ",b=" & b & "]{Test}") Thanks for this snipped, Hans. It looks promising, but I get the following compile error:
!mplib : mp terminal: >> "\colored [r=" >> 0.74464 ! Not implemented: (string)&(known numeric). <to be read again> I used the following code: \starttext \startuseMPgraphic {1} numeric r, g, b ; r := uniformdeviate 1 ; g := uniformdeviate 1 ; b := uniformdeviate 1 ; label(textext("\colored[r=" & r & ",g=" & g & ",b=" & b & "]{Test}"), origin); \stopuseMPgraphic \useMPgraphic {1} \stoptext Marco