mIRC Home    About    Download    Register    News    Help

Topic Options
#188065 - 17/10/07 04:44 AM floating text
WideOpenSpace Offline
Vogon poet

Registered: 13/06/07
Posts: 157
Loc: ???
can anyone (willing) write a code
that would make text written in EDIT control on dialog
to float like <marqee> tags do for html ?
_________________________
The harder I chase my dreams the more I experience the time for smiles and tears...

Top
#188068 - 17/10/07 05:29 AM Re: floating text [Re: WideOpenSpace]
genius_at_work Offline
Hoopy frood

Registered: 08/10/05
Posts: 1741
This code can be used to scroll a string of text from one end to the other. Unfortunately, due to mIRC's space character limitations, you can't make it appear to be scrolling across like the <marquee> tag. You may be able to make the marquee work properly with the use of a dll like spaces.dll.

Code:
alias mq.start {
  ;*** Call to start the scrolling
  unset %mq.*
  set %mq.point 0
  .timer.mq -m 0 500 mq.disp
}

alias mq.stop {
  unset %mq.*
  .timer.mq off
}

alias mq.disp {
  ;*** Scrolls one character for each call (chr(32) ignored)
  var %mq.title = This is the text to scroll in the textbox
  inc %mq.point 1
  if (%mq.point > $len(%mq.title)) set %mq.point 1
  if ($mid(%mq.title,%mq.point,1) == $chr(32)) inc %mq.point 1
  var %mq.disp = $right(%mq.title,$calc($len(%mq.title) - %mq.point)) $left(%mq.title,%mq.point)
  echo -a did -ra <id_of_dialog_item> %mq.disp
}



Change the value of %mq.title to scroll whatever you want.

/sb.start to start the scroll action.
/sb.stop to stop it.

-genius_at_work

Top
#188069 - 17/10/07 05:35 AM Re: floating text [Re: genius_at_work]
Lpfix5 Offline
Hoopy frood

Registered: 10/08/05
Posts: 1052
Loc: Canada
what about $chr(160) instead of 32?
_________________________
Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }

Top
#188088 - 17/10/07 03:10 PM Re: floating text [Re: Lpfix5]
genius_at_work Offline
Hoopy frood

Registered: 08/10/05
Posts: 1741
If that is what they want to do, and if chr160 shows up as a space on their font.

-genius_at_work

Top
#188091 - 17/10/07 06:23 PM Re: floating text [Re: genius_at_work]
WideOpenSpace Offline
Vogon poet

Registered: 13/06/07
Posts: 157
Loc: ???
thank you so much ^^
_________________________
The harder I chase my dreams the more I experience the time for smiles and tears...

Top