mirror of
https://github.com/ArthurSonzogni/FTXUI.git
synced 2025-11-15 11:38:56 +08:00
282 lines
20 KiB
HTML
282 lines
20 KiB
HTML
<!-- HTML header for doxygen 1.8.14-->
|
|
<!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="cache-control" content="max-age=86400"/>
|
|
<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.12.0"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>FTXUI: include/ftxui/component/component_base.hpp File 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="navtree.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="navtreedata.js"></script>
|
|
<script type="text/javascript" src="navtree.js"></script>
|
|
<script type="text/javascript" src="resize.js"></script>
|
|
<script type="text/javascript" src="cookie.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" />
|
|
<link href="doxygen_extra.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">FTXUI
|
|
 <span id="projectnumber">4.1.0</span>
|
|
</div>
|
|
<div id="projectbrief">C++ functional terminal UI.</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.12.0 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
var searchBox = new SearchBox("searchBox", "search/",'.html');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
$(function() { codefold.init(0); });
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="menudata.js"></script>
|
|
<script type="text/javascript" src="menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
$(function() {
|
|
initMenu('',true,false,'search.php','Search',true);
|
|
$(function() { init_search(); });
|
|
});
|
|
/* @license-end */
|
|
</script>
|
|
<div id="main-nav"></div>
|
|
</div><!-- top -->
|
|
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
|
<div id="nav-tree">
|
|
<div id="nav-tree-contents">
|
|
<div id="nav-sync" class="sync"></div>
|
|
</div>
|
|
</div>
|
|
<div id="splitbar" style="-moz-user-select:none;"
|
|
class="ui-resizable-handle">
|
|
</div>
|
|
</div>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
|
|
$(function(){initNavTree('component__base_8hpp.html',''); initResizable(true); });
|
|
/* @license-end */
|
|
</script>
|
|
<div id="doc-content">
|
|
<!-- 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">
|
|
<div id="MSearchResults">
|
|
<div class="SRPage">
|
|
<div id="SRIndex">
|
|
<div id="SRResults"></div>
|
|
<div class="SRStatus" id="Loading">Loading...</div>
|
|
<div class="SRStatus" id="Searching">Searching...</div>
|
|
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#nested-classes">Data Structures</a> |
|
|
<a href="#namespaces">Namespaces</a> |
|
|
<a href="#typedef-members">Typedefs</a> </div>
|
|
<div class="headertitle"><div class="title">component_base.hpp File Reference</div></div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<div class="textblock"><div id="dynsection-0" onclick="return dynsection.toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;">
|
|
<img id="dynsection-0-trigger" src="closed.png" alt="+"/> This graph shows which files directly or indirectly include this file:</div>
|
|
<div id="dynsection-0-summary" class="dynsummary" style="display:block;">
|
|
</div>
|
|
<div id="dynsection-0-content" class="dyncontent" style="display:none;">
|
|
<div class="center"><img src="component__base_8hpp__dep__incl.png" border="0" usemap="#ainclude_2ftxui_2component_2component__base_8hppdep" alt=""/></div>
|
|
<map name="ainclude_2ftxui_2component_2component__base_8hppdep" id="ainclude_2ftxui_2component_2component__base_8hppdep">
|
|
<area shape="rect" title=" " alt="" coords="1447,5,1626,45"/>
|
|
<area shape="rect" href="component_8hpp.html" title=" " alt="" coords="1447,181,1626,221"/>
|
|
<area shape="poly" title=" " alt="" coords="1539,59,1539,181,1534,181,1534,59"/>
|
|
<area shape="rect" href="button_8cpp.html" title=" " alt="" coords="529,269,680,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1434,34,1107,57,941,74,874,85,823,96,768,111,725,124,687,146,647,183,632,204,622,227,610,270,605,269,617,225,628,201,643,180,684,141,723,119,766,105,821,91,873,79,941,69,1106,51,1434,29"/>
|
|
<area shape="rect" href="catch__event_8cpp.html" title=" " alt="" coords="1773,269,1924,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1557,56,1614,136,1653,180,1697,219,1742,247,1789,267,1787,272,1740,251,1694,223,1649,184,1610,139,1553,59"/>
|
|
<area shape="rect" href="checkbox_8cpp.html" title=" " alt="" coords="704,269,855,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1435,49,1346,70,1255,96,1129,140,1006,189,820,272,818,267,1004,185,1127,135,1253,91,1345,65,1433,44"/>
|
|
<area shape="rect" href="collapsible_8cpp.html" title=" " alt="" coords="5,269,156,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1434,31,1218,37,949,49,691,68,584,81,504,96,445,113,387,134,275,183,180,232,112,272,110,267,178,228,273,178,385,129,444,108,503,91,584,75,690,63,949,44,1218,32,1434,26"/>
|
|
<area shape="rect" href="component_8cpp.html" title=" " alt="" coords="1948,269,2099,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1571,53,1615,91,1679,158,1716,195,1747,219,1826,242,1948,269,1947,275,1824,247,1745,224,1712,199,1675,162,1611,95,1567,57"/>
|
|
<area shape="rect" href="container_8cpp.html" title=" " alt="" coords="2123,269,2273,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1586,50,1652,91,1684,119,1724,158,1764,195,1798,219,1842,237,1881,248,1949,255,2021,257,2110,267,2123,269,2122,274,2110,272,2020,262,1949,261,1880,253,1840,242,1795,224,1760,199,1720,162,1680,123,1648,95,1583,54"/>
|
|
<area shape="rect" href="dropdown_8cpp.html" title=" " alt="" coords="180,269,331,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1433,31,1239,37,1001,49,775,68,682,81,612,96,562,113,512,134,418,183,338,232,282,271,279,267,335,228,415,179,510,129,560,108,611,91,681,75,774,62,1001,43,1238,32,1433,26"/>
|
|
<area shape="rect" href="hoverable_8cpp.html" title=" " alt="" coords="2297,269,2448,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1604,48,1648,67,1693,91,1728,119,1770,158,1813,195,1849,219,1911,241,1965,254,2015,259,2062,259,2161,257,2219,259,2286,267,2298,269,2297,274,2286,272,2219,264,2161,262,2062,265,2014,264,1964,259,1909,246,1846,224,1809,199,1766,162,1724,123,1690,96,1646,72,1602,53"/>
|
|
<area shape="rect" href="input_8cpp.html" title=" " alt="" coords="355,269,505,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1434,31,1255,35,1042,46,841,66,759,79,698,96,658,113,620,134,549,183,490,232,450,271,446,267,487,228,546,179,617,130,656,108,696,91,758,74,840,60,1042,41,1255,30,1433,25"/>
|
|
<area shape="rect" href="maybe_8cpp.html" title=" " alt="" coords="2472,269,2623,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1625,47,1681,66,1735,91,1772,118,1817,157,1862,195,1899,219,1980,246,2050,260,2113,264,2174,263,2301,256,2375,258,2461,267,2472,269,2471,274,2460,272,2375,263,2301,262,2174,268,2113,270,2049,265,1978,251,1897,224,1858,199,1813,161,1769,122,1733,96,1679,71,1624,52"/>
|
|
<area shape="rect" href="menu_8cpp.html" title=" " alt="" coords="879,269,1029,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1464,52,1346,96,1242,142,1142,191,989,272,987,267,1139,187,1240,137,1344,91,1462,47"/>
|
|
<area shape="rect" href="modal_8cpp.html" title=" " alt="" coords="2647,269,2797,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,44,1710,63,1779,91,1818,118,1864,157,1911,195,1950,219,2014,235,2095,246,2289,255,2484,258,2568,261,2636,267,2647,268,2646,274,2635,272,2568,266,2484,263,2289,260,2095,251,2013,240,1948,224,1908,199,1861,161,1815,122,1777,96,1708,68,1639,49"/>
|
|
<area shape="rect" href="radiobox_8cpp.html" title=" " alt="" coords="1053,269,1204,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1488,54,1413,96,1265,192,1155,271,1152,267,1262,188,1410,91,1485,49"/>
|
|
<area shape="rect" href="renderer_8cpp.html" title=" " alt="" coords="2821,269,2972,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,38,1731,58,1779,73,1825,91,1865,117,1912,157,1960,195,2000,219,2076,237,2173,248,2283,254,2401,256,2632,257,2731,260,2810,267,2822,268,2821,274,2810,272,2731,265,2632,263,2401,262,2283,259,2172,254,2075,242,1998,224,1957,199,1909,161,1861,122,1822,96,1777,78,1730,63,1639,43"/>
|
|
<area shape="rect" href="resizable__split_8cpp.html" title=" " alt="" coords="1228,269,1379,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1500,56,1453,95,1411,142,1373,191,1318,271,1313,268,1368,188,1407,139,1449,91,1496,52"/>
|
|
<area shape="rect" href="slider_8cpp.html" title=" " alt="" coords="1403,269,1553,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1512,58,1471,113,1452,147,1438,182,1434,201,1438,221,1449,246,1464,268,1459,271,1444,248,1433,222,1429,201,1433,181,1447,144,1466,110,1508,54"/>
|
|
<area shape="rect" href="component_2util_8cpp.html" title=" " alt="" coords="2996,269,3147,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,33,1754,53,1814,69,1873,91,2045,219,2085,231,2132,240,2245,252,2373,258,2510,259,2778,258,2893,260,2985,267,2996,268,2995,274,2984,272,2893,265,2778,263,2510,264,2373,263,2244,258,2131,245,2083,236,2042,224,1870,96,1813,74,1753,58,1639,38"/>
|
|
<area shape="rect" href="component__options_8hpp.html" title=" " alt="" coords="835,93,1017,133"/>
|
|
<area shape="poly" title=" " alt="" coords="1434,42,1037,96,1018,99,1017,94,1036,91,1433,37"/>
|
|
<area shape="rect" href="loop_8hpp.html" title=" " alt="" coords="2055,93,2234,133"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,37,2037,91,2056,94,2055,99,2036,96,1639,42"/>
|
|
<area shape="rect" href="screen__interactive_8cpp.html" title=" " alt="" coords="2231,181,2405,221"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,23,1793,25,1970,35,2056,43,2134,55,2199,71,2247,91,2271,110,2290,134,2314,180,2309,182,2285,137,2267,114,2245,96,2198,76,2133,60,2055,49,1970,40,1793,31,1640,28"/>
|
|
<area shape="poly" title=" " alt="" coords="1433,209,1102,228,897,247,692,272,681,274,680,268,691,267,897,241,1102,223,1433,204"/>
|
|
<area shape="poly" title=" " alt="" coords="1619,222,1781,267,1780,272,1618,228"/>
|
|
<area shape="poly" title=" " alt="" coords="1434,212,1176,234,1021,251,866,272,855,274,854,269,866,267,1020,245,1175,228,1433,207"/>
|
|
<area shape="poly" title=" " alt="" coords="1434,208,789,231,430,250,281,260,168,272,157,274,156,268,167,267,280,255,430,244,789,226,1434,203"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,216,1936,267,1948,269,1947,274,1935,272,1640,221"/>
|
|
<area shape="rect" href="component__fuzzer_8cpp.html" title=" " alt="" coords="1577,269,1749,309"/>
|
|
<area shape="poly" title=" " alt="" coords="1578,227,1637,267,1634,271,1575,232"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,209,1857,232,2110,267,2123,269,2122,274,2110,272,1856,237,1639,214"/>
|
|
<area shape="poly" title=" " alt="" coords="1433,206,1231,209,960,219,653,239,496,254,342,272,331,274,330,268,342,267,495,248,652,234,960,214,1231,204,1433,200"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,208,1983,235,2159,252,2286,267,2298,269,2297,274,2286,272,2158,257,1983,240,1640,213"/>
|
|
<area shape="poly" title=" " alt="" coords="1434,207,1260,212,1031,224,775,243,517,272,506,274,505,268,516,267,774,237,1031,218,1259,207,1434,202"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,207,2105,238,2461,267,2472,268,2471,274,2460,272,2104,243,1639,212"/>
|
|
<area shape="poly" title=" " alt="" coords="1434,217,1250,240,1041,272,1030,274,1029,269,1040,267,1250,235,1433,212"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,205,2197,236,2475,253,2636,267,2647,268,2646,274,2635,272,2475,259,2197,241,1640,211"/>
|
|
<area shape="poly" title=" " alt="" coords="1435,226,1216,272,1205,274,1204,269,1215,267,1434,221"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,205,2313,238,2810,267,2822,268,2821,274,2810,272,2313,244,1640,210"/>
|
|
<area shape="poly" title=" " alt="" coords="1474,229,1355,272,1354,267,1472,224"/>
|
|
<area shape="poly" title=" " alt="" coords="1518,234,1493,271,1489,268,1514,231"/>
|
|
<area shape="poly" title=" " alt="" coords="1640,204,2407,237,2985,267,2996,268,2995,274,2984,272,2407,243,1639,210"/>
|
|
<area shape="poly" title=" " alt="" coords="1031,127,1447,185,1447,190,1030,132"/>
|
|
<area shape="poly" title=" " alt="" coords="914,147,888,187,871,207,851,224,786,246,681,273,680,268,784,241,849,219,867,203,884,184,909,144"/>
|
|
<area shape="poly" title=" " alt="" coords="925,148,916,186,896,223,865,251,831,271,828,267,862,247,892,220,911,184,920,147"/>
|
|
<area shape="poly" title=" " alt="" coords="821,126,635,147,528,164,423,184,263,228,132,272,131,267,261,222,421,179,527,158,634,142,821,121"/>
|
|
<area shape="poly" title=" " alt="" coords="822,131,692,153,551,184,413,228,300,272,299,267,411,223,549,179,690,147,821,126"/>
|
|
<area shape="poly" title=" " alt="" coords="822,136,735,156,646,184,545,228,463,271,461,267,542,223,644,179,733,151,821,131"/>
|
|
<area shape="poly" title=" " alt="" coords="939,146,947,181,956,269,951,269,942,182,934,147"/>
|
|
<area shape="poly" title=" " alt="" coords="960,140,1108,267,1105,271,957,144"/>
|
|
<area shape="poly" title=" " alt="" coords="980,137,1263,267,1261,272,978,142"/>
|
|
<area shape="poly" title=" " alt="" coords="999,135,1419,267,1417,272,998,140"/>
|
|
<area shape="rect" href="component__options_8cpp.html" title=" " alt="" coords="657,181,838,221"/>
|
|
<area shape="poly" title=" " alt="" coords="876,142,788,184,785,179,873,137"/>
|
|
<area shape="rect" href="loop_8cpp.html" title=" " alt="" coords="2056,181,2207,221"/>
|
|
<area shape="poly" title=" " alt="" coords="2142,147,2137,182,2132,181,2137,146"/>
|
|
<area shape="poly" title=" " alt="" coords="2196,137,2281,179,2279,184,2194,142"/>
|
|
</map>
|
|
</div>
|
|
</div>
|
|
<p><a href="component__base_8hpp_source.html">Go to the source code of this file.</a></p>
|
|
<table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="nested-classes" name="nested-classes"></a>
|
|
Data Structures</h2></td></tr>
|
|
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">class  </td><td class="memItemRight" valign="bottom"><a class="el" href="classftxui_1_1ComponentBase.html">ComponentBase</a></td></tr>
|
|
<tr class="memdesc:"><td class="mdescLeft"> </td><td class="mdescRight">It implement rendering itself as <a class="el" href="namespaceftxui.html#a2bc31f2d685189e5c61d2293a1f51b4f">ftxui::Element</a>. It implement keyboard navigation by responding to <a class="el" href="structftxui_1_1Event.html" title="Represent an event. It can be key press event, a terminal resize, or more ...">ftxui::Event</a>. <a href="classftxui_1_1ComponentBase.html#details">More...</a><br /></td></tr>
|
|
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="namespaces" name="namespaces"></a>
|
|
Namespaces</h2></td></tr>
|
|
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">namespace  </td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceftxui.html">ftxui</a></td></tr>
|
|
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">namespace  </td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceftxui_1_1animation.html">ftxui::animation</a></td></tr>
|
|
<tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="typedef-members" name="typedef-members"></a>
|
|
Typedefs</h2></td></tr>
|
|
<tr class="memitem:af1479ede01dbf087342534ab4ada11d3" id="r_af1479ede01dbf087342534ab4ada11d3"><td class="memItemLeft" align="right" valign="top">using </td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceftxui.html#af1479ede01dbf087342534ab4ada11d3">Component</a> = std::shared_ptr<<a class="el" href="classftxui_1_1ComponentBase.html">ComponentBase</a>></td></tr>
|
|
<tr class="separator:af1479ede01dbf087342534ab4ada11d3"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a3d4ccad0c8a07d5b0cb4b2e690ffc90c" id="r_a3d4ccad0c8a07d5b0cb4b2e690ffc90c"><td class="memItemLeft" align="right" valign="top">using </td><td class="memItemRight" valign="bottom"><a class="el" href="namespaceftxui.html#a3d4ccad0c8a07d5b0cb4b2e690ffc90c">Components</a> = std::vector<<a class="el" href="namespaceftxui.html#af1479ede01dbf087342534ab4ada11d3">Component</a>></td></tr>
|
|
<tr class="separator:a3d4ccad0c8a07d5b0cb4b2e690ffc90c"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
</div><!-- contents -->
|
|
</div><!-- doc-content -->
|
|
<!-- HTML footer for doxygen 1.8.14-->
|
|
<!-- start footer part -->
|
|
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
|
</div>
|
|
<script>
|
|
document.addEventListener('DOMContentLoaded', function() {
|
|
const projectNumber = document.getElementById('projectnumber');
|
|
if (!projectNumber) {
|
|
console.warn('Doxygen element with ID "projectnumber" not found. Cannot add version switcher.');
|
|
return;
|
|
}
|
|
|
|
const versions = ["main", "v6.1.9", "v6.1.8", "v6.1.7", "v6.1.6", "v6.1.5", "v6.1.4", "v6.1.3", "v6.1.2", "v6.1.1", "v6.1.0", "v6.0.2", "v6.0.1", "v6.0.0", "v5.0.0", "v4.1.1", "v4.1.0", "v4.0.0", "v3.0.0", "v2.0.0", "v0.9", "v0.11", "v0.10"];
|
|
const version_paths = {"main": "../../index.html", "v6.1.9": "../v6.1.9/index.html", "v6.1.8": "../v6.1.8/index.html", "v6.1.7": "../v6.1.7/index.html", "v6.1.6": "../v6.1.6/index.html", "v6.1.5": "../v6.1.5/index.html", "v6.1.4": "../v6.1.4/index.html", "v6.1.3": "../v6.1.3/index.html", "v6.1.2": "../v6.1.2/index.html", "v6.1.1": "../v6.1.1/index.html", "v6.1.0": "../v6.1.0/index.html", "v6.0.2": "../v6.0.2/index.html", "v6.0.1": "../v6.0.1/index.html", "v6.0.0": "../v6.0.0/index.html", "v5.0.0": "../v5.0.0/index.html", "v4.1.1": "../v4.1.1/index.html", "v4.1.0": "index.html", "v4.0.0": "../v4.0.0/index.html", "v3.0.0": "../v3.0.0/index.html", "v2.0.0": "../v2.0.0/index.html", "v0.9": "../v0.9/index.html", "v0.11": "../v0.11/index.html", "v0.10": "../v0.10/index.html"};
|
|
const currentVersion = "v4.1.0";
|
|
|
|
// Sort versions: 'main' first, then others numerically descending.
|
|
versions.sort((a, b) => {
|
|
if (a === 'main') return -1;
|
|
if (b === 'main') return 1;
|
|
return b.localeCompare(a, undefined, { numeric: true, sensitivity: 'base' });
|
|
});
|
|
|
|
const select = document.createElement('select');
|
|
select.onchange = function() {
|
|
const selectedVersion = this.value;
|
|
// Navigate directly to the pre-calculated relative path.
|
|
if (selectedVersion !== currentVersion) {
|
|
window.location.href = version_paths[selectedVersion];
|
|
}
|
|
};
|
|
|
|
versions.forEach(v => {
|
|
const option = document.createElement('option');
|
|
option.value = v;
|
|
option.textContent = v;
|
|
if (v === currentVersion) {
|
|
option.selected = true;
|
|
}
|
|
select.appendChild(option);
|
|
});
|
|
|
|
// Replace the Doxygen project number element with our dropdown.
|
|
projectNumber.replaceWith(select);
|
|
|
|
// Apply some styling to make it look good.
|
|
Object.assign(select.style, {
|
|
backgroundColor: 'rgba(0, 0, 0, 0.8)',
|
|
color: 'white',
|
|
border: '1px solid rgba(255, 255, 255, 0.2)',
|
|
padding: '5px',
|
|
borderRadius: '5px',
|
|
fontSize: '14px',
|
|
fontFamily: 'inherit',
|
|
marginLeft: '10px',
|
|
cursor: 'pointer'
|
|
});
|
|
});
|
|
</script>
|
|
</body>
|
|
</html>
|