Search
Unit.empty Method
See Also
Collapse All Expand All Language Filter: All Language Filter: Multiple Language Filter: None Language Filter: C# Language Filter: Visual Basic Language Filter: Java Language Filter: JavaScript Language Filter: C++ Language Filter: XAML
C#
Visual Basic
Java
JavaScript
C++
XAML
Introduction
General Information
What's New In This Release
Version History
Getting Started
Code Completion With VSDoc IntelliSense
Programming Interface Overview
Tutorials
Reference
MindFusion.Common
Control Class
DateFormats Class
DateSettings Class
EventDispatcher Class
IdGenerator Class
Locale Class
NotifyCollectionChangedAction Class
NotifyCollectionChangedEventArgs Class
NotifyCollectionChangingEventArgs Class
PropertyEventArgs Class
UIControl Class
Unit Class
Unit Members
Unit Constructor
Unit Methods
empty Method
parse Method
percentage Method
pixel Method
toString Method
Unit Properties
UnitType Enumeration
MindFusion.Common.Collections
MindFusion.Controls
MindFusion.Scheduling
Licensing
Online Resources
Technical Support
MindFusion Products

Creates an empty Unit instance.

Namespace: MindFusion.Common
Assembly: Unit.js

## Syntax

JavaScript Copy Code
function empty ()

### Return Value

Unit. The new Unit.

## Example

The following code creates a new ListView and sets its minWidth to an empty Unit.

JavaScript Copy Code
var ui = MindFusion.UI; var listView; var host; var theme = "gray"; document.addEventListener("DOMContentLoaded", function () { listView = new ui.ListView(document.getElementById("listView")); listView.minWidth = ui.Unit.empty(); listView.width = listView.height = ui.Unit.percentage(100); listView.theme = theme; listView.itemSize = ui.Unit.pixel(100); listView.itemDoubleClick.addEventListener(handleItemDoubleClick); .......................................... .......................................... }

## See Also

Unit Members
Unit Class
MindFusion.Common Namespace