Display

By mSLChampagne on Nov 28, 2010

Change event, message, and highlight colours via script.

alias display { 
  if ($istok(event message highlight,$1,32)) {
    if  (!$com($wsh)) { 
      .comopen $wsh wscript.shell
      if (!$comerr) && ($com($wsh)) { 
        var %keys = $+($(%o,),$str(LLD,8),$str(LLU,8),DDDDD)
        if ($1 = event)     %keys = %keys $+ $str(T,10)
        if ($1 = message)   %keys = %keys $+ $str(T,11)
        if ($1 = highlight) %keys = %keys $+ $str(T,12)
        noop $com($wsh,sendkeys,1,string,$keystroke(%keys))
        %keys = $+($str(U,17),$str(D,$iif($2 isnum,$2,0)),~)
        .comclose $wsh $com($wsh,sendkeys,1,string,$keystroke(%keys))
      }
    }
  }
}

alias -l keystroke return $replace($1,D,{DOWN},T,{TAB},U,{UP},L,{LEFT})
alias -l wsh return obj.display.options

Comments

Sign in to comment.
Burrito   -  Nov 28, 2010

Why isn't your user COMChampagne

 Respond  
mSLChampagne   -  Nov 28, 2010

Possible, and entirely likely. ;D

 Respond  
Jethro   -  Nov 28, 2010

Looks like we got ourselves a COM fanatic here. ^^

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.