Horstl, I already know that $window can't be overridden by custom aliases (though /window can). That was a response to your request that they "try this"... advice containing those two words often isn't particularly useful advice. What was the point of your question?

To be clear and concise:
Code:
echo -s window -g0 $qt($window(*,%i))

Would result in a correct return value, regardless of a "custom alias", providing %i evaluates to a numeric value >= 0 and <= $window(*,0).

Originally Posted By: westor
Also if this will help you try this:

Code:
alias markread {
  var %i = 1
  while ($window(*,%i).wid) {
    window -g0 @ $+ $v1
    inc %i
  }
}
alias f2 scon -a markread


And for closing all the query windows just type : /closemsg

Thankyou for teaching me something undocumented. How did you come about learning this?

Last edited by s00p; 29/11/09 07:58 AM.