Class Index | File Index

Classes


Class CatalogTexture


Defined in: SweetHome3D.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
CatalogTexture(id, name, image, width, height, modifiable, creator)
Creates a catalog texture.
Method Summary
Method Attributes Method Name and Description
 
compareTo(texture)
Compares the names of this texture and the one in parameter.
 
equals(obj)
Returns true if this texture and the one in parameter are the same objects.
 
Returns the category of this texture.
 
Returns the creator of this texture or null.
 
Returns the height of the image in centimeters.
 
Returns the icon of this texture.
 
Returns the ID of this texture or null.
 
Returns the content of the image used for this texture.
 
Returns the name of this texture.
 
Returns the width of the image in centimeters.
 
Returns true if this texture is modifiable (not read from resources).
 
matchesFilter(filter)
Returns true if this texture matches the given filter text.
 
setCategory(category)
Sets the category of this texture.
Class Detail
CatalogTexture(id, name, image, width, height, modifiable, creator)
Creates a catalog texture.
Author: Emmanuel Puybaret.
Parameters:
{string} id
the ID of this texture
{string} name
the name of this texture
{Object} image
the content of the image used for this texture
{number} width
the width of the texture in centimeters
{number} height
the height of the texture in centimeters
{boolean} modifiable
true if this texture can be modified
{string} creator
Method Detail
{number} compareTo(texture)
Compares the names of this texture and the one in parameter.
Parameters:
{CatalogTexture} texture
Returns:
{number}

{boolean} equals(obj)
Returns true if this texture and the one in parameter are the same objects. Note that, from version 3.6, two textures can have the same name.
Parameters:
{Object} obj
Returns:
{boolean}

{TexturesCategory} getCategory()
Returns the category of this texture.
Returns:
{TexturesCategory}

{string} getCreator()
Returns the creator of this texture or null.
Returns:
{string}

{number} getHeight()
Returns the height of the image in centimeters.
Returns:
{number}

{Object} getIcon()
Returns the icon of this texture.
Returns:
{Object} the image of this texture.

{string} getId()
Returns the ID of this texture or null.
Returns:
{string}

{Object} getImage()
Returns the content of the image used for this texture.
Returns:
{Object}

{string} getName()
Returns the name of this texture.
Returns:
{string}

{number} getWidth()
Returns the width of the image in centimeters.
Returns:
{number}

{boolean} isModifiable()
Returns true if this texture is modifiable (not read from resources).
Returns:
{boolean}

{boolean} matchesFilter(filter)
Returns true if this texture matches the given filter text. Each substring of the filter is considered as a search criterion that can match the name, the category name or the creator of this texture.
Parameters:
{string} filter
Returns:
{boolean}

setCategory(category)
Sets the category of this texture.
Parameters:
{TexturesCategory} category

© Copyrights 2017 Emmanuel PUYBARET / eTeks
Distributed under GNU General Public License
Documentation generated by JsDoc Toolkit 2.4.0 on Wed Oct 25 2017 16:36:08 GMT+0200 (CEST)