Update chart layout (for example if container is resized)
3174
function() {
                            if (scope.chart && scope.svg) {
                                if (scope.options.chart.type === 'sunburstChart') {
                                    scope.svg.datum(angular.copy(scope.data)).call(scope.chart);
                                } else {
                                    scope.svg.datum(scope.data).call(scope.chart);
                                }
                            } else {
                                scope.api.refresh();
                            }
                        }
737979
function() {

		var resizeTimeout;
		var resizeHandler = function() {
			F2.Events.emit(F2.Constants.Events.CONTAINER_WIDTH_CHANGE);
		};

		jQuery(window).on('resize', function() {
			clearTimeout(resizeTimeout);
			resizeTimeout = setTimeout(resizeHandler, 100);
		});

		//listen for container-broadcasted locale changes
		F2.Events.on(F2.Constants.Events.CONTAINER_LOCALE_CHANGE,function(data){
			if (data.locale && typeof data.locale == 'string'){
				F2.ContainerConfig.locale = data.locale;
			}
		});
	}
516764
def update_margins(self):
        """"""
        layout = self.layout()
        if self.default_margins is None:
            self.default_margins = layout.getContentsMargins()
        if CONF.get('main', 'use_custom_margin'):
            margin = CONF.get('main', 'custom_margin')
            layout.setContentsMargins(*[margin]*4)
        else:
            layout.setContentsMargins(*self.default_margins)
266882
def update_floating_panels(self):
        """"""
        crect = self.editor.contentsRect()
        panels = self.panels_for_zone(Panel.Position.FLOATING)
        for panel in panels:
            if not panel.isVisible():
                continue
            panel.set_geometry(crect)
150589
def refresh_table(self):
        """"""
        if self.is_visible and self.isVisible():
            self.shellwidget.refresh_namespacebrowser()
            try:
                self.editor.resizeRowToContents()
            except TypeError:
                pass
1092606
def OnUpdateFigurePanel(self, event):
        """"""

        if self.updating:
            return

        self.updating = True
        self.figure_panel.update(self.get_figure(self.code))
        self.updating = False
316050
function updateGap(acediff, editor, scroll) {
  clearDiffs(acediff);
  decorate(acediff);

  // reposition the copy containers containing all the arrows
  positionCopyContainers(acediff);
}
1118089
function myOnresizebeforedraw (obj)
            {
                var gutterLeft = obj.Get('chart.gutter.left');
                var gutterRight = obj.Get('chart.gutter.right');
            
                obj.Set('chart.hmargin', (obj.canvas.width - gutterLeft - gutterRight) / (obj.original_data[0].length * 2));
            }
1313779
function(chart) {
            var tooltipRefresh = chart.tooltip.refresh,
                decorateTooltip = (this.processedData.xAxisType === 'time') ?
                        this.addTimeTooltipClasses.bind(this) : this.addTooltipClasses.bind(this);

            this.addDataClasses(chart);
            this.addAxisClasses(chart);
            if(chart.options.legend.enabled) {
                this.addLegendClasses(chart);
            }
            chart.tooltip.refresh = function(point) {
                tooltipRefresh(point);
                decorateTooltip(chart);
            }.bind(this);
        }
7009
function() {
		var me = this;

		if (plugins.notify(me, 'beforeLayout') === false) {
			return;
		}

		layouts.update(this, this.width, this.height);

		/**
		 * Provided for backward compatibility, use `afterLayout` instead.
		 * @method IPlugin#afterScaleUpdate
		 * @deprecated since version 2.5.0
		 * @todo remove at version 3
		 * @private
		 */
		plugins.notify(me, 'afterScaleUpdate');
		plugins.notify(me, 'afterLayout');
	}
199074
def _update_viewport_margins(self):
        """"""
        top = 0
        left = 0
        right = 0
        bottom = 0
        for panel in self.panels_for_zone(Panel.Position.LEFT):
            if panel.isVisible():
                width = panel.sizeHint().width()
                left += width
        for panel in self.panels_for_zone(Panel.Position.RIGHT):
            if panel.isVisible():
                width = panel.sizeHint().width()
                right += width
        for panel in self.panels_for_zone(Panel.Position.TOP):
            if panel.isVisible():
                height = panel.sizeHint().height()
                top += height
        for panel in self.panels_for_zone(Panel.Position.BOTTOM):
            if panel.isVisible():
                height = panel.sizeHint().height()
                bottom += height
        self._margin_sizes = (top, left, right, bottom)
        self.editor.setViewportMargins(left, top, right, bottom)
884557
function updateLayoutInfo(name) {
      var layouts = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

      if (!menus.has(name)) {
        return;
      }

      var menu = Object.assign({}, menus.get(name));

      if (layouts.hasOwnProperty('triggerLayout')) {
        menu.triggerLayout = layouts.triggerLayout;
      }

      if (layouts.hasOwnProperty('optionsLayout')) {
        menu.optionsLayout = layouts.optionsLayout;
      }

      menus.set(name, menu);
    }
1052510
protected void updateGui() {
		ButtonLayoutStyle buttonButtonLayoutStyle = buttonAction.getButtonLayoutStyle();
		if (ButtonLayoutStyle.ICON_TITLE_AND_DESCRIPTION.equals(buttonButtonLayoutStyle)) {
			buildGuiWithDescription();
		} else { // LayoutParameter.Layout.ICON_AND_TITLE || null || ...
			setWidth(50);
			if (titleAlignment.equals(TitleAlignment.BOTTOM)) {
				setHeight100();
				
				outer = new VStack();
				outer.setOverflow(Overflow.VISIBLE);
				outer.setWidth(GuwLayout.ribbonButtonWidth);
				outer.setAutoHeight();
				outer.addMember(icon);
				if (showTitles && !GuwLayout.hideRibbonTitles) {
					titleLabel.setBaseStyle(getBaseStyle() + "LargeTitle");
					titleLabel.setAutoHeight();
					titleLabel.setWidth(GuwLayout.ribbonButtonWidth);
					outer.addMember(titleLabel);
				}
				outer.setAlign(Alignment.CENTER);
			} else {
				setAutoHeight();
				
				outer = new HStack(GuwLayout.ribbonButtonInnerMargin);
				outer.setOverflow(Overflow.VISIBLE);
				outer.setWidth100();
				outer.setAutoHeight();
				outer.addMember(icon);
				if (showTitles) {
					titleLabel.setBaseStyle(getBaseStyle() + "SmallTitle");
					titleLabel.setAutoHeight();
					titleLabel.setAutoWidth();
					outer.addMember(titleLabel);
				}
			} 
		}
	}
796749
function fixContainerSizeNow() {
               if( !showContent || !scope.isVisible ) { return; }
               let contentHeight = 0;
               jqElement.children().each( ( index, child ) => {
                  contentHeight += $( child ).outerHeight( true );
               } );
               if( contentHeight !== currentTargetHeight ) {
                  animateToHeight( jqElement, contentHeight );
                  // if this widget contains another animated widget (such as another AxShowHideWidget),
                  // make sure to pick up on its animated content
                  $window.setTimeout( fixContainerSize, RESIZE_DELAY );
               }
            }
973934
function _updateLayout() {

		this._bChangedByMe = true;
		this._changedFormContainers = [];

		var sLayout = this.getLayout();
		var oLayout = this.getAggregation("form").getLayout();

		oLayout.setBackgroundDesign(this.getBackgroundDesign());

		switch (sLayout) {
		case SimpleFormLayout.ResponsiveLayout:
			// set the default values for linebreakes to avoid flickering for default case
			this._applyLinebreaks();

			for ( var i = 0; i < this._changedFormElements.length; i++) {
				var oFormElement = this._changedFormElements[i];
				_applyFieldWeight.call(this, oFormElement);
			}
			break;
		case SimpleFormLayout.GridLayout:
			_applyContainerSize.call(this);
			break;
		case SimpleFormLayout.ResponsiveGridLayout:
			oLayout.setLabelSpanXL(this.getLabelSpanXL());
			oLayout.setLabelSpanL(this.getLabelSpanL());
			oLayout.setLabelSpanM(this.getLabelSpanM());
			oLayout.setLabelSpanS(this.getLabelSpanS());
			oLayout.setAdjustLabelSpan(this.getAdjustLabelSpan());
			oLayout.setEmptySpanXL(this.getEmptySpanXL());
			oLayout.setEmptySpanL(this.getEmptySpanL());
			oLayout.setEmptySpanM(this.getEmptySpanM());
			oLayout.setEmptySpanS(this.getEmptySpanS());
			oLayout.setColumnsXL(this.getColumnsXL());
			oLayout.setColumnsL(this.getColumnsL());
			oLayout.setColumnsM(this.getColumnsM());
			oLayout.setSingleContainerFullSize(this.getSingleContainerFullSize());
			oLayout.setBreakpointXL(this.getBreakpointXL());
			oLayout.setBreakpointL(this.getBreakpointL());
			oLayout.setBreakpointM(this.getBreakpointM());
			break;
		case SimpleFormLayout.ColumnLayout:
			oLayout.setColumnsXL(this.getColumnsXL() > 0 ? this.getColumnsXL() : this.getColumnsL());
			oLayout.setColumnsL(this.getColumnsL());
			oLayout.setColumnsM(this.getColumnsM());
			oLayout.setLabelCellsLarge(this.getLabelSpanL());
			oLayout.setEmptyCellsLarge(this.getEmptySpanL());
			break;
			// no default
		}

		this._changedFormElements = [];
		this._bChangedByMe = false;

	}
469174
protected void layoutCharts() {
        //Pre-sort charts by group column
        MultiValuedMap<DJGroup, DJChart> mmap = new ArrayListValuedHashMap<DJGroup, DJChart>();
        for (DJChart djChart : getReport().getCharts()) {
            mmap.put(djChart.getColumnsGroup(), djChart);
        }

        for (DJGroup key : mmap.keySet()) {
            Collection<DJChart> charts = mmap.get(key);
            List<DJChart> l = new ArrayList<DJChart>(charts);
            //Reverse iteration of the charts to meet insertion order
            for (int i = l.size(); i > 0; i--) {
                DJChart djChart = l.get(i - 1);
                JRDesignChart chart = createChart(djChart);

                //Charts has their own band, so they are added in the band at Y=0
                JRDesignBand band = createGroupForChartAndGetBand(djChart);
                band.addElement(chart);
            }
        }

        //Pre-sort charts by group column
        MultiValuedMap<PropertyColumn, ar.com.fdvs.dj.domain.chart.DJChart> mmap2 = new ArrayListValuedHashMap<PropertyColumn, ar.com.fdvs.dj.domain.chart.DJChart>();
        for (ar.com.fdvs.dj.domain.chart.DJChart djChart : getReport().getNewCharts()) {
            mmap2.put(djChart.getDataset().getColumnsGroup(), djChart);
        }

        for (PropertyColumn key : mmap2.keySet()) {
            Collection<ar.com.fdvs.dj.domain.chart.DJChart> charts = mmap2.get(key);
            ArrayList<ar.com.fdvs.dj.domain.chart.DJChart> l = new ArrayList<ar.com.fdvs.dj.domain.chart.DJChart>(charts);
            //Reverse iteration of the charts to meet insertion order
            for (int i = l.size(); i > 0; i--) {
                ar.com.fdvs.dj.domain.chart.DJChart djChart = l.get(i - 1);
                String name = "chart_" + (i - 1) + new Date().getTime();
                JRDesignChart chart = createChart(djChart, name);

                if (djChart.getLink() != null)
                    HyperLinkUtil.applyHyperLinkToElement((DynamicJasperDesign) getDesign(), djChart.getLink(), chart, name + "_hyperlink");

                //Charts has their own band, so they are added in the band at Y=0
                JRDesignBand band = createGroupForChartAndGetBand(djChart);
                band.addElement(chart);
            }
        }
    }
672843
function(isInit) {
                var containerWidth = self.$map.width();

                if (self.paper.width !== containerWidth) {
                    var newScale = containerWidth / self.mapConf.width;
                    // Set new size
                    self.paper.setSize(containerWidth, self.mapConf.height * newScale);

                    // Create plots legend again to take into account the new scale
                    // Do not do this on init (it will be done later)
                    if (isInit !== true && self.options.legend.redrawOnResize) {
                        self.createLegends("plot", self.plots, newScale);
                    }
                }
            }