TDE System Settings – easy to use control center
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

39 lines
1.3 KiB

  1. /*
  2. Copyright (c) 2006 Simon Edwards <simon@simonzone.com>
  3. This library is free software; you can redistribute it and/or
  4. modify it under the terms of the GNU Library General Public
  5. License as published by the Free Software Foundation; either
  6. version 2 of the License, or (at your option) any later version.
  7. This library is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  10. Library General Public License for more details.
  11. You should have received a copy of the GNU Library General Public License
  12. along with this library; see the file COPYING.LIB. If not, write to
  13. the Free Software Foundation, Inc., 51 Franklin Steet, Fifth Floor,
  14. Boston, MA 02110-1301, USA.
  15. */
  16. #include "kcscrollview.h"
  17. KCScrollView::KCScrollView( TQWidget * parent, const char * name, WFlags f) : TQScrollView(parent,name,f) {
  18. setResizePolicy(AutoOneFit);
  19. mainChild = 0;
  20. }
  21. TQSize KCScrollView::tqsizeHint() const {
  22. TQSize vphint = mainChild->tqsizeHint();
  23. vphint.setWidth(vphint.width()+2*frameWidth());
  24. vphint.setHeight(vphint.height()+2*frameWidth());
  25. return vphint;
  26. }
  27. void KCScrollView::addChild(TQWidget *child, int x, int y) {
  28. mainChild = child;
  29. TQScrollView::addChild(child,x,y);
  30. }