Skip to content
Related Articles
Get the best out of our app
Open App

Related Articles

jQWidgets jqxPanel sizeMode Property

Improve Article
Save Article
Like Article
Improve Article
Save Article
Like Article

jQWidgets is a JavaScript framework for making web-based applications for PC and mobile devices. It is a very powerful, optimized, platform-independent, and widely supported framework. The jqxPanel is used to illustrate a jQuery panel widget which is a holder for different widgets or elements. Moreover, it intuitively appends horizontal as well as vertical scrollbars, in case the stated content is not completely viewable.

The sizeMode property is used to set or return the mode of sizing in the displayed jqxPanel. It has 2 possible values, namely, fixed and wrap. In the case of fixed mode, the scrollbar will be displayed only when needed & in the case of wrap mode, the scrollbar is not displayed & the panel will be auto-resized. It is of type string and its by default value is fixed.


  • Setting the sizeMode Property:
$("#Selector").jqxPanel({ sizeMode: 'fixed' });
  • Return the sizeMode Property:
var sizeMode = $('#Selector').jqxPanel('sizeMode');

Linked Files: Download jQWidgets from the given link. In the HTML file, locate the script files in the downloaded folder.

<link rel=”stylesheet” href=”jqwidgets/styles/jqx.base.css” type=”text/css” />
<script type=”text/javascript” src=”scripts/jquery-1.11.1.min.js”></script>
<script type=”text/javascript” src=”jqwidgets/jqxcore.js”></script>
<script type=”text/javascript” src=”jqwidgets/jqxbuttons.js”></script>
<script type=”text/javascript” src=”jqwidgets/jqxscrollbar.js”></script>
<script type=”text/javascript” src=”jqwidgets/jqxpanel.js”></script>

Example: The below example illustrates the jqxPanel sizeMode Property in jQWidgets.


<!DOCTYPE html>
<html lang="en">
    <link rel="stylesheet" 
        type="text/css" />
    <script type="text/javascript" 
    <script type="text/javascript" 
    <script type="text/javascript" 
    <script type="text/javascript" 
    <script type="text/javascript" 
        <h1 style="color:green">
          jQWidgets jqxPanel sizeMode Property
        <div id='jqxp' 
            <div style='margin-top: 12px;'>
                <h3>Topics covered by GeeksforGeeks</h3>
            <div style="white-space: nowrap; 
                        text-align: left;">
                    <li>Theory Of Computation</li>
                    <li>C Programming</li>
            <input type="button" 
                style="margin-top: 25px" 
                value="Click here"/>
        <div id="log"></div>
    <script type="text/javascript">
        $(document).ready(function () {
                width: "180px",
                height: "170px",
                theme: 'energyblue',
                sizeMode: 'wrap',
                width: "180px",
                height: "30px",
                theme: 'energyblue',
            $("#jqxBtn").on("click", function () {
                var m = $('#jqxp').jqxPanel('sizeMode');
                $('#log').html("Sizing mode used: " + m);




My Personal Notes arrow_drop_up
Last Updated : 23 May, 2022
Like Article
Save Article
Similar Reads
Related Tutorials