This file is indexed.

/usr/share/doc/libjuce/apiref/classStretchableLayoutManager.html is in libjuce-doc 4.3.0~repack-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.12"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>JUCE: StretchableLayoutManager Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">JUCE
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.12 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="classStretchableLayoutManager-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">StretchableLayoutManager Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p>For laying out a set of components, where the components have preferred sizes and size limits, but where they are allowed to stretch to fill the available space.  
 <a href="classStretchableLayoutManager.html#details">More...</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a1fc7dc605c628265d33d6d189df8dbdf"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#a1fc7dc605c628265d33d6d189df8dbdf">StretchableLayoutManager</a> ()</td></tr>
<tr class="memdesc:a1fc7dc605c628265d33d6d189df8dbdf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates an empty layout.  <a href="#a1fc7dc605c628265d33d6d189df8dbdf">More...</a><br /></td></tr>
<tr class="separator:a1fc7dc605c628265d33d6d189df8dbdf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac163f26b08dba15724f71e846a204e7d"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#ac163f26b08dba15724f71e846a204e7d">~StretchableLayoutManager</a> ()</td></tr>
<tr class="memdesc:ac163f26b08dba15724f71e846a204e7d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor.  <a href="#ac163f26b08dba15724f71e846a204e7d">More...</a><br /></td></tr>
<tr class="separator:ac163f26b08dba15724f71e846a204e7d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad06dde1deb392bbe53d9c642302a3e01"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#ad06dde1deb392bbe53d9c642302a3e01">setItemLayout</a> (int itemIndex, double minimumSize, double maximumSize, double preferredSize)</td></tr>
<tr class="memdesc:ad06dde1deb392bbe53d9c642302a3e01"><td class="mdescLeft">&#160;</td><td class="mdescRight">For a numbered item, this sets its size limits and preferred size.  <a href="#ad06dde1deb392bbe53d9c642302a3e01">More...</a><br /></td></tr>
<tr class="separator:ad06dde1deb392bbe53d9c642302a3e01"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab253f9079d87d4528c11d3418625bb15"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#ab253f9079d87d4528c11d3418625bb15">getItemLayout</a> (int itemIndex, double &amp;minimumSize, double &amp;maximumSize, double &amp;preferredSize) const</td></tr>
<tr class="memdesc:ab253f9079d87d4528c11d3418625bb15"><td class="mdescLeft">&#160;</td><td class="mdescRight">For a numbered item, this returns its size limits and preferred size.  <a href="#ab253f9079d87d4528c11d3418625bb15">More...</a><br /></td></tr>
<tr class="separator:ab253f9079d87d4528c11d3418625bb15"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a11eb6cecef28d174591a4f638807631d"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#a11eb6cecef28d174591a4f638807631d">clearAllItems</a> ()</td></tr>
<tr class="memdesc:a11eb6cecef28d174591a4f638807631d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Clears all the properties that have been set with <a class="el" href="classStretchableLayoutManager.html#ad06dde1deb392bbe53d9c642302a3e01" title="For a numbered item, this sets its size limits and preferred size. ">setItemLayout()</a> and resets this object to its initial state.  <a href="#a11eb6cecef28d174591a4f638807631d">More...</a><br /></td></tr>
<tr class="separator:a11eb6cecef28d174591a4f638807631d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8276cd18109ff9bb5220b1d91dad1c90"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#a8276cd18109ff9bb5220b1d91dad1c90">layOutComponents</a> (<a class="el" href="classComponent.html">Component</a> **components, int numComponents, int x, int y, int width, int height, bool vertically, bool resizeOtherDimension)</td></tr>
<tr class="memdesc:a8276cd18109ff9bb5220b1d91dad1c90"><td class="mdescLeft">&#160;</td><td class="mdescRight">Takes a set of components that correspond to the layout's items, and positions them to fill a space.  <a href="#a8276cd18109ff9bb5220b1d91dad1c90">More...</a><br /></td></tr>
<tr class="separator:a8276cd18109ff9bb5220b1d91dad1c90"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3cc6c6f61e7c5d08bdc1460576cccb91"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#a3cc6c6f61e7c5d08bdc1460576cccb91">getItemCurrentPosition</a> (int itemIndex) const</td></tr>
<tr class="memdesc:a3cc6c6f61e7c5d08bdc1460576cccb91"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the current position of one of the items.  <a href="#a3cc6c6f61e7c5d08bdc1460576cccb91">More...</a><br /></td></tr>
<tr class="separator:a3cc6c6f61e7c5d08bdc1460576cccb91"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a029e0c56d4c72eadd53298c564adb21b"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#a029e0c56d4c72eadd53298c564adb21b">getItemCurrentAbsoluteSize</a> (int itemIndex) const</td></tr>
<tr class="memdesc:a029e0c56d4c72eadd53298c564adb21b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the current size of one of the items.  <a href="#a029e0c56d4c72eadd53298c564adb21b">More...</a><br /></td></tr>
<tr class="separator:a029e0c56d4c72eadd53298c564adb21b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa4b73d670e6b6c316f03b0ec5042184e"><td class="memItemLeft" align="right" valign="top">double&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#aa4b73d670e6b6c316f03b0ec5042184e">getItemCurrentRelativeSize</a> (int itemIndex) const</td></tr>
<tr class="memdesc:aa4b73d670e6b6c316f03b0ec5042184e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the current size of one of the items.  <a href="#aa4b73d670e6b6c316f03b0ec5042184e">More...</a><br /></td></tr>
<tr class="separator:aa4b73d670e6b6c316f03b0ec5042184e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8c9f25baf3358d5b5ba1619fdac75e83"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classStretchableLayoutManager.html#a8c9f25baf3358d5b5ba1619fdac75e83">setItemPosition</a> (int itemIndex, int newPosition)</td></tr>
<tr class="memdesc:a8c9f25baf3358d5b5ba1619fdac75e83"><td class="mdescLeft">&#160;</td><td class="mdescRight">Moves one of the items, shifting along any other items as necessary in order to get it to the desired position.  <a href="#a8c9f25baf3358d5b5ba1619fdac75e83">More...</a><br /></td></tr>
<tr class="separator:a8c9f25baf3358d5b5ba1619fdac75e83"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>For laying out a set of components, where the components have preferred sizes and size limits, but where they are allowed to stretch to fill the available space. </p>
<p>For example, if you have a component containing several other components, and each one should be given a share of the total size, you could use one of these to resize the child components when the parent component is resized. Then you could add a <a class="el" href="classStretchableLayoutResizerBar.html" title="A component that acts as one of the vertical or horizontal bars you see being used to resize panels i...">StretchableLayoutResizerBar</a> to easily let the user rescale them.</p>
<p>A <a class="el" href="classStretchableLayoutManager.html" title="For laying out a set of components, where the components have preferred sizes and size limits...">StretchableLayoutManager</a> operates only in one dimension, so if you have a set of components stacked vertically on top of each other, you'd use one to manage their heights. To build up complex arrangements of components, e.g. for applications with multiple nested panels, you would use more than one <a class="el" href="classStretchableLayoutManager.html" title="For laying out a set of components, where the components have preferred sizes and size limits...">StretchableLayoutManager</a>. E.g. by using two (one vertical, one horizontal), you could create a resizable spreadsheet-style table.</p>
<p>E.g. </p><div class="fragment"><div class="line"><span class="keyword">class </span>MyComp  : <span class="keyword">public</span> <a class="code" href="classComponent.html">Component</a></div><div class="line">{</div><div class="line">    <a class="code" href="classStretchableLayoutManager.html">StretchableLayoutManager</a> myLayout;</div><div class="line"></div><div class="line">    MyComp()</div><div class="line">    {</div><div class="line">        myLayout.<a class="code" href="classStretchableLayoutManager.html#ad06dde1deb392bbe53d9c642302a3e01">setItemLayout</a> (0,          <span class="comment">// for item 0</span></div><div class="line">                                50, 100,    <span class="comment">// must be between 50 and 100 pixels in size</span></div><div class="line">                                -0.6);      <span class="comment">// and its preferred size is 60% of the total available space</span></div><div class="line"></div><div class="line">        myLayout.<a class="code" href="classStretchableLayoutManager.html#ad06dde1deb392bbe53d9c642302a3e01">setItemLayout</a> (1,          <span class="comment">// for item 1</span></div><div class="line">                                -0.2, -0.6, <span class="comment">// size must be between 20% and 60% of the available space</span></div><div class="line">                                50);        <span class="comment">// and its preferred size is 50 pixels</span></div><div class="line">    }</div><div class="line"></div><div class="line">    <span class="keywordtype">void</span> resized()</div><div class="line">    {</div><div class="line">        <span class="comment">// make a list of two of our child components that we want to reposition</span></div><div class="line">        <a class="code" href="classComponent.html">Component</a>* comps[] = { myComp1, myComp2 };</div><div class="line"></div><div class="line">        <span class="comment">// this will position the 2 components, one above the other, to fit</span></div><div class="line">        <span class="comment">// vertically into the rectangle provided.</span></div><div class="line">        myLayout.<a class="code" href="classStretchableLayoutManager.html#a8276cd18109ff9bb5220b1d91dad1c90">layOutComponents</a> (comps, 2,</div><div class="line">                                   0, 0, getWidth(), getHeight(),</div><div class="line">                                   <span class="keyword">true</span>);</div><div class="line">    }</div><div class="line">};</div></div><!-- fragment --><dl class="section see"><dt>See also</dt><dd><a class="el" href="classStretchableLayoutResizerBar.html" title="A component that acts as one of the vertical or horizontal bars you see being used to resize panels i...">StretchableLayoutResizerBar</a> </dd></dl>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a1fc7dc605c628265d33d6d189df8dbdf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1fc7dc605c628265d33d6d189df8dbdf">&sect;&nbsp;</a></span>StretchableLayoutManager()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">StretchableLayoutManager::StretchableLayoutManager </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Creates an empty layout. </p>
<p>You'll need to add some item properties to the layout before it can be used to resize things - see <a class="el" href="classStretchableLayoutManager.html#ad06dde1deb392bbe53d9c642302a3e01" title="For a numbered item, this sets its size limits and preferred size. ">setItemLayout()</a>. </p>

</div>
</div>
<a id="ac163f26b08dba15724f71e846a204e7d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac163f26b08dba15724f71e846a204e7d">&sect;&nbsp;</a></span>~StretchableLayoutManager()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">StretchableLayoutManager::~StretchableLayoutManager </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Destructor. </p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="ad06dde1deb392bbe53d9c642302a3e01"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad06dde1deb392bbe53d9c642302a3e01">&sect;&nbsp;</a></span>setItemLayout()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void StretchableLayoutManager::setItemLayout </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>itemIndex</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>minimumSize</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>maximumSize</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double&#160;</td>
          <td class="paramname"><em>preferredSize</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>For a numbered item, this sets its size limits and preferred size. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">itemIndex</td><td>the index of the item to change. </td></tr>
    <tr><td class="paramname">minimumSize</td><td>the minimum size that this item is allowed to be - a positive number indicates an absolute size in pixels. A negative number indicates a proportion of the available space (e.g -0.5 is 50%) </td></tr>
    <tr><td class="paramname">maximumSize</td><td>the maximum size that this item is allowed to be - a positive number indicates an absolute size in pixels. A negative number indicates a proportion of the available space </td></tr>
    <tr><td class="paramname">preferredSize</td><td>the size that this item would like to be, if there's enough room. A positive number indicates an absolute size in pixels. A negative number indicates a proportion of the available space </td></tr>
  </table>
  </dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classStretchableLayoutManager.html#ab253f9079d87d4528c11d3418625bb15" title="For a numbered item, this returns its size limits and preferred size. ">getItemLayout</a> </dd></dl>

</div>
</div>
<a id="ab253f9079d87d4528c11d3418625bb15"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab253f9079d87d4528c11d3418625bb15">&sect;&nbsp;</a></span>getItemLayout()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool StretchableLayoutManager::getItemLayout </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>itemIndex</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double &amp;&#160;</td>
          <td class="paramname"><em>minimumSize</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double &amp;&#160;</td>
          <td class="paramname"><em>maximumSize</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">double &amp;&#160;</td>
          <td class="paramname"><em>preferredSize</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>For a numbered item, this returns its size limits and preferred size. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">itemIndex</td><td>the index of the item. </td></tr>
    <tr><td class="paramname">minimumSize</td><td>the minimum size that this item is allowed to be - a positive number indicates an absolute size in pixels. A negative number indicates a proportion of the available space (e.g -0.5 is 50%) </td></tr>
    <tr><td class="paramname">maximumSize</td><td>the maximum size that this item is allowed to be - a positive number indicates an absolute size in pixels. A negative number indicates a proportion of the available space </td></tr>
    <tr><td class="paramname">preferredSize</td><td>the size that this item would like to be, if there's enough room. A positive number indicates an absolute size in pixels. A negative number indicates a proportion of the available space </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>false if the item's properties hadn't been set </dd></dl>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classStretchableLayoutManager.html#ad06dde1deb392bbe53d9c642302a3e01" title="For a numbered item, this sets its size limits and preferred size. ">setItemLayout</a> </dd></dl>

</div>
</div>
<a id="a11eb6cecef28d174591a4f638807631d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a11eb6cecef28d174591a4f638807631d">&sect;&nbsp;</a></span>clearAllItems()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void StretchableLayoutManager::clearAllItems </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Clears all the properties that have been set with <a class="el" href="classStretchableLayoutManager.html#ad06dde1deb392bbe53d9c642302a3e01" title="For a numbered item, this sets its size limits and preferred size. ">setItemLayout()</a> and resets this object to its initial state. </p>

</div>
</div>
<a id="a8276cd18109ff9bb5220b1d91dad1c90"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8276cd18109ff9bb5220b1d91dad1c90">&sect;&nbsp;</a></span>layOutComponents()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void StretchableLayoutManager::layOutComponents </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="classComponent.html">Component</a> **&#160;</td>
          <td class="paramname"><em>components</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>numComponents</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>x</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>y</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>height</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>vertically</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>resizeOtherDimension</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Takes a set of components that correspond to the layout's items, and positions them to fill a space. </p>
<p>This will try to give each item its preferred size, whether that's a relative size or an absolute one.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">components</td><td>an array of components that correspond to each of the numbered items that the <a class="el" href="classStretchableLayoutManager.html" title="For laying out a set of components, where the components have preferred sizes and size limits...">StretchableLayoutManager</a> object has been told about with <a class="el" href="classStretchableLayoutManager.html#ad06dde1deb392bbe53d9c642302a3e01" title="For a numbered item, this sets its size limits and preferred size. ">setItemLayout()</a> </td></tr>
    <tr><td class="paramname">numComponents</td><td>the number of components in the array that is passed-in. This should be the same as the number of items this object has been told about. </td></tr>
    <tr><td class="paramname">x</td><td>the left of the rectangle in which the components should be laid out </td></tr>
    <tr><td class="paramname">y</td><td>the top of the rectangle in which the components should be laid out </td></tr>
    <tr><td class="paramname">width</td><td>the width of the rectangle in which the components should be laid out </td></tr>
    <tr><td class="paramname">height</td><td>the height of the rectangle in which the components should be laid out </td></tr>
    <tr><td class="paramname">vertically</td><td>if true, the components will be positioned in a vertical stack, so that they fill the height of the rectangle. If false, they will be placed side-by-side in a horizontal line, filling the available width </td></tr>
    <tr><td class="paramname">resizeOtherDimension</td><td>if true, this means that the components will have their other dimension resized to fit the space - i.e. if the 'vertically' parameter is true, their x-positions and widths are adjusted to fit the x and width parameters; if 'vertically' is false, their y-positions and heights are adjusted to fit the y and height parameters. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a id="a3cc6c6f61e7c5d08bdc1460576cccb91"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3cc6c6f61e7c5d08bdc1460576cccb91">&sect;&nbsp;</a></span>getItemCurrentPosition()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int StretchableLayoutManager::getItemCurrentPosition </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>itemIndex</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns the current position of one of the items. </p>
<p>This is only a valid call after <a class="el" href="classStretchableLayoutManager.html#a8276cd18109ff9bb5220b1d91dad1c90" title="Takes a set of components that correspond to the layout&#39;s items, and positions them to fill a space...">layOutComponents()</a> has been called, as it returns the last position that this item was placed at. If the layout was vertical, the value returned will be the y position of the top of the item, relative to the top of the rectangle in which the items were placed (so for example, item 0 will always have position of 0, even in the rectangle passed in to <a class="el" href="classStretchableLayoutManager.html#a8276cd18109ff9bb5220b1d91dad1c90" title="Takes a set of components that correspond to the layout&#39;s items, and positions them to fill a space...">layOutComponents()</a> wasn't at y = 0). If the layout was done horizontally, the position returned is the item's left-hand position, again relative to the x position of the rectangle used.</p>
<dl class="section see"><dt>See also</dt><dd>getItemCurrentSize, <a class="el" href="classStretchableLayoutManager.html#a8c9f25baf3358d5b5ba1619fdac75e83" title="Moves one of the items, shifting along any other items as necessary in order to get it to the desired...">setItemPosition</a> </dd></dl>

</div>
</div>
<a id="a029e0c56d4c72eadd53298c564adb21b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a029e0c56d4c72eadd53298c564adb21b">&sect;&nbsp;</a></span>getItemCurrentAbsoluteSize()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int StretchableLayoutManager::getItemCurrentAbsoluteSize </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>itemIndex</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns the current size of one of the items. </p>
<p>This is only meaningful after <a class="el" href="classStretchableLayoutManager.html#a8276cd18109ff9bb5220b1d91dad1c90" title="Takes a set of components that correspond to the layout&#39;s items, and positions them to fill a space...">layOutComponents()</a> has been called, as it returns the last size that this item was given. If the layout was done vertically, it'll return the item's height in pixels; if it was horizontal, it'll return its width.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classStretchableLayoutManager.html#aa4b73d670e6b6c316f03b0ec5042184e" title="Returns the current size of one of the items. ">getItemCurrentRelativeSize</a> </dd></dl>

</div>
</div>
<a id="aa4b73d670e6b6c316f03b0ec5042184e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa4b73d670e6b6c316f03b0ec5042184e">&sect;&nbsp;</a></span>getItemCurrentRelativeSize()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">double StretchableLayoutManager::getItemCurrentRelativeSize </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>itemIndex</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Returns the current size of one of the items. </p>
<p>This is only meaningful after <a class="el" href="classStretchableLayoutManager.html#a8276cd18109ff9bb5220b1d91dad1c90" title="Takes a set of components that correspond to the layout&#39;s items, and positions them to fill a space...">layOutComponents()</a> has been called, as it returns the last size that this item was given. If the layout was done vertically, it'll return a negative value representing the item's height relative to the last size used for laying the components out; if the layout was done horizontally it'll be the proportion of its width.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classStretchableLayoutManager.html#a029e0c56d4c72eadd53298c564adb21b" title="Returns the current size of one of the items. ">getItemCurrentAbsoluteSize</a> </dd></dl>

</div>
</div>
<a id="a8c9f25baf3358d5b5ba1619fdac75e83"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8c9f25baf3358d5b5ba1619fdac75e83">&sect;&nbsp;</a></span>setItemPosition()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void StretchableLayoutManager::setItemPosition </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>itemIndex</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>newPosition</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Moves one of the items, shifting along any other items as necessary in order to get it to the desired position. </p>
<p>Calling this method will also update the preferred sizes of the items it shuffles along, so that they reflect their new positions.</p>
<p>(This is the method that a <a class="el" href="classStretchableLayoutResizerBar.html" title="A component that acts as one of the vertical or horizontal bars you see being used to resize panels i...">StretchableLayoutResizerBar</a> uses to shift the items about when it's dragged).</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">itemIndex</td><td>the item to move </td></tr>
    <tr><td class="paramname">newPosition</td><td>the absolute position that you'd like this item to move to. The item might not be able to always reach exactly this position, because other items may have minimum sizes that constrain how far it can go </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="juce__StretchableLayoutManager_8h.html">juce_StretchableLayoutManager.h</a></li>
</ul>
</div><!-- contents -->
<hr class="footer"/>
<address class="footer"><small>All content &copy ROLI Ltd.</small></address><br/>
</body>
</html>