<table><tr><td style="">romangg added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D14353">View Revision</a></tr></table><br /><div><div><p>As already said on IRC and also how Vlad sees it: this optimization like for most of our classes is not worth it.</p>

<p>Since we are an open source project, which strives to motivate people to contribute, good readability is much more important. So when ordering the class members we should think of our code as technical documents, whose structure should make it easy for new contributors to learn what the code is doing.</p>

<p>This means that when describing a class general and more important properties should be at the top (e.g. here id, name, type) and more specific or less important ones are at the bottom (e.g. here rotation, scale). Also properties should be grouped if they show similarities (e.g. here pos, size, rotation, scale).</p>

<p>If we have a class in our code where tighter packing really makes sense (much more instances), a comment in the class description should indicate this. Otherwise the default ordering mode should be better readability.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R110 KScreen Library</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D14353">https://phabricator.kde.org/D14353</a></div></div><br /><div><strong>To: </strong>gladhorn, Plasma, romangg<br /><strong>Cc: </strong>zzag, romangg, plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart<br /></div>