On October 2, 2009, Thomas Olsen wrote: > - After having created the UI and layout in init() I need to resize the > Plasmoid the a reasonable size as it is too small without specifying it > [1]. I don't want to use a fixed pixel size as this can be wrong for > different themes, fonts etc. I tried to resize it based on the max/minimum > width/height of the main layout but that caused plasma-desktop to eat all > memory and eventually crash so I guess thats the wrong way to do it ;-) > What is the best practice for setting the initial size?
does the widget use a top level layout? you should be able to just set a default reasonable size in the ctor and then the layout can expand the widget if needed. > - Yesterday I redesigned the layout and in the process I mistakenly > deleted a line that made the Plasmoid ignore aspect ratio and now I don't > remember where I found it, if it was a call to Plasma::Applet, the layout > or whatever. Does anyone have a clue what I'm talking about? I know it > sounds a bit hazy :-) setAspectRatioMode(Plasma::IgnoreAspectRatio) -- Aaron J. Seigo humru othro a kohnu se GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA EE75 D6B7 2EB1 A7F1 DB43 KDE core developer sponsored by Qt Development Frameworks
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel