<doc>
  <legacy_id>1183</legacy_id>
  <name>scrollbarDrag</name>
  <type>message</type>
  <syntax>
    <example>scrollbarDrag <i>newPosition</i></example>
  </syntax>
  <library></library>
  <objects>
    <field/>
  </objects>
  <synonyms>
  </synonyms>
  <classification>
    <category>User Interaction</category>
  </classification>
  <references>
    <message tag="scrollbarBeginning">scrollbarBeginning Message</message>
  </references>
  <history>
    <introduced version="1.0">Added.</introduced>
  </history>
  <platforms>
    <mac/>
    <windows/>
    <linux/>
    <ios/>
    <android/>
  </platforms>
  <classes>
    <desktop/>
    <server/>
    <web/>
    <mobile/>
  </classes>
  <security>
  </security>
  <summary>Sent to a <keyword tag="field">field</keyword>, <keyword tag="scrollbar">scrollbar</keyword>, or <command tag="group">group</command> when the user drags the <glossary tag="scrollbar thumb">scrollbar thumb</glossary> or when a text <keyword tag="selection">selection</keyword> causes a <keyword tag="field">field</keyword> to scroll.</summary>
  <examples>
    <example>on scrollbarDrag newValue <code><i>-- display current line number</i></code></p><p>  put newValue div the textHeight of me + 1 into field "Line Number"</p><p>end scrollbarDrag</example>
  </examples>
  <description>
    <p>Handle the <b>scrollbarDrag</b> <keyword tag="message box">message</keyword> if you want to respond to the user dragging the <glossary tag="scrollbar thumb">scrollbar thumb</glossary>: for example, to update a counter on the <keyword tag="card">card</keyword>.</p><p/><p><b>Parameters:</b></p><p>The <i>newPosition</i> is the new position of the <glossary tag="scrollbar thumb">scrollbar thumb</glossary>. This <glossary tag="parameter">parameter</glossary> is <glossary tag="pass">passed</glossary> only if the <glossary tag="object">object</glossary> is a <keyword tag="scrollbar">scrollbar</keyword>.</p><p/><p><b>Comments:</b></p><p>If the user clicks one of the arrows or the gray region of the scrollbar, and the appropriate message is not handled anywhere in the message path, a <b>scrollbarDrag</b> <keyword tag="message box">message</keyword> is sent. In other words, you can use a <b>scrollbarDrag</b> <glossary tag="handler">handler</glossary> to <glossary tag="handle">handle</glossary> all <keyword tag="scrollbar">scrollbar</keyword> movements.</p><p/><p>If the <b>select</b> <glossary tag="command">command</glossary> is used to <command tag="select">select</command> text within a scrolling <keyword tag="field">field</keyword>, and this causes the <keyword tag="field">field</keyword> to scroll to bring the <property tag="selected">selected</property> text into view, a <b>scrollbarDrag</b> <keyword tag="message box">message</keyword> is sent to the <keyword tag="field">field</keyword>.</p>
  </description>
</doc>