Problem/Issue 5240
 
Query for PDR ID
Example: search for PDR ID 109-9999 , just enter 9999 into the entry field and press ENTER.
Open Build: Open Date: Language:
1.80.284 02.04.2003 (All)
Closed Build: Close Date: Platform:
1.82.306 07.04.2004 ALL
State: Reference PDR ID: Hotfix Rollup No.:
CLOSED    
Symptom:
XbpListBox(): Horiz. scrollbar not adjusted for tab stops
Description:
When using the :setTabStops() method of an XbpListbox object to
set tab stops for the items in the list, the horizontal scrollbar
(see :horizScroll instance variable) of the XbpListbox object
does not adjust the scrollable area. This may cause tabbed columns
to be outside the area that can be made visible with the scrollbar.








Solution:
Starting with Xbase++ 1.82.0306, the method "XbpListbox:setScrollWidth()"
can be used to set the scrollable area of the listbox object. Alaska
Software is planning to release the new version of the XbpListbox
component via a public fix level (PFL) for Xbase++ 1.82. Please visit
our website at www.alaska-software.com to learn when this PFL will
become available.

":SetScrollWidth()" can be used to set the scrollable area of
the listbox object. Parameter "nWidth" must be specified in pixels.

Example:

   (...)

   aTabs     := oListbox:getTabStops()
   IF Len(aTabs) > 0
      nWidthTAB := aTabs[Len(aTabs)] * (nAveCharWidth/4)
      nWidthTAB += ( Len("ColumnHeader   ") * nAveCharWidth )
      oListbox:setScrollWidth( nWidthTAB  )
   ENDIF

   (...)

The example code first checks whether any tab stops had been set
previously. If so, it proceeds to compute the position of the last
tab stop in pixels. It does so by using the average character width
of the font which can be determined as follows:

  oPS := oListbox:lockPS()
  nAveCharWidth := oPS:setFont():width
  oListBox:unlockPS()

When the position of the last tab stop has been computed, it adds the
length of the column header string ("ColumnHeader") plus a safety
margin. Finally, the scrollable area of the listbox is set to the
value computed. Whenever the listbox object is made smaller than this
value, a scrollbar is displayed.



 
(C) Copyright Alaska Software Inc. 2008, All rights reserved!
Disclaimer, Limitation of Liability, no Warranty: THE INFORMATION, DOCUMENTS, FILES AND MATERIALS CONTAINED IN THIS SITE ARE PROVIDED "AS IS". ALASKA SOFTWARE DOES NOT WARRANT THE ACCURACY, ADEQUACY OR COMPLETENESS OF THIS INFORMATION AND MATERIALS; THUS EXPRESSLY DISCLAIMS LIABILITY FOR ERRORS OR OMISSIONS IN THIS INFORMATION AND MATERIALS.
WARRANTIES OF ANY KIND, IMPLIED, EXPRESSED OR STATUTORY, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF NON-INFRINGEMENT OF THIRD PARTY RIGHTS, TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR RESOLVEMENT-CLAIMS, ARE DISCLAIMED.