TextBox

扩展自 $.fn.validatebox.defaults. 重写 $.fn.textbox.defaults.

TextBox 是加强的输入控件,使我们建设表单更加快捷. 是一些复杂控件的基础控件,比如 combo,datebox,spinner,等等.

依赖

validatebox

linkbutton

实例

html创建方式

javascript创建方式

$('#tb').textbox({

buttonText:'Search',

iconCls:'icon-man',

iconAlign:'left'

})

属性

属性拓展自 validatebox 控件,下面是textbox新添加的属性:

Name

Type

Description

Default

width

number

The width of the component.

auto

height

number

The height of the component.

22

prompt

string

The prompt message to be displayed in input box.

''

value

string

The default value.

type

string

The textbox type. Possible values are 'text' and 'password'.

text

multiline

boolean

Defines if this is a multiline textbox.

false

editable

boolean

Defines if user can type text directly into the field.

true

disabled

boolean

Defines if to disable the field.

false

readonly

boolean

Defines if the component is read-only.

false

icons

array

The icons attached to the textbox. Each item has the following properties:

iconCls: string, the icon class.

disabled: boolean, indicate if the icon is disabled.

handler: function, the function to process the clicking action on this icon.

Code example:

$('#tb').textbox({

icons: [{

iconCls:'icon-add',

handler: function(e){

$(e.data.target).textbox('setValue', 'Something added!');

}

},{

iconCls:'icon-remove',

handler: function(e){

$(e.data.target).textbox('clear');

}

}]

})

[]

iconCls

string

The background icon displayed on the textbox.

null

iconAlign

string

Position of the icons. Possible values are 'left','right'.

right

iconWidth

number

The icon width.

18

buttonText

string

The displaying text of button that attached to the textbox.

buttonIcon

string

The displaying icon of button that attached to the textbox.

null

buttonAlign

string

Position of the button. Possible values are 'left','right'.

right

事件

事件拓展自 validatebox 控件,下面是textbox新添加的事件:

Name

Parameters

Description

onChange

newValue,oldValue

Fires when the field value is changed.

onResize

width,height

Fires when the textbox is resized.

onClickButton

none

Fires when the user click the button.

onClickIcon

index

Fires when the user click a icon.

方法

方法拓展自 validatebox 控件,下面是textbox新添加的方法:

Name

Parameter

Description

options

none

Return the options object.

textbox

none

Return the textbox object.

button

none

Return the button object.

destroy

none

Destroy the textbox component.

resize

width

Resize the component width.

disable

none

Disable the component.

enable

none

Enable the component.

readonly

mode

Enable/Disable readonly mode.

Code example:

$('#tb').textbox('readonly');// enable readonly mode

$('#tb').textbox('readonly',true);// eanble readonly mode

$('#tb').textbox('readonly',false);// disable readonly mode

clear

none

Clear the component value.

reset

none

Reset the component value.

setText

text

Set the displaying text value.

getText

none

Get the displaying text value.

setValue

value

Set the component value.

getValue

none

Get the component value.

getIcon

index

Get specified icon object.

FileBox

拓展自 $.fn.textbox.defaults. 重写 $.fn.filebox.defaults.

由于浏览器安全问题, 一些方法 比如 'setValue' 不能使用filebox 组件.

依赖

textbox

实例

html创建方式

javascript创建方式

$('#fb').filebox({

buttonText: 'Choose File',

buttonAlign: 'left'

})

属性

属性拓展自 textbox, 下面是 filebox新增属性.

Name

Type

Description

Default

buttonText

string

The displaying text of button that attached to the textbox.

Choose File

buttonIcon

string

The displaying icon of button that attached to the textbox.

null

buttonAlign

string

Position of the button. Possible values are 'left','right'.

right

事件

事件拓展自 textbox.

方法

方法拓展自 textbox.



php easyui filebox,EasyUI1.4 新控件TextBox,FileBox相关推荐

  1. 【Android】Anroid5.0+新控件---酷炫标题栏的简单学习

    Android5.0+推出的新控件感觉特别酷,最近想模仿大神做个看图App出来,所以先把这些新控件用熟悉了. 新控件的介绍.使用等等网上相应的文章已经特别多了,题主也没那能力去写篇详解出来,本篇随笔记 ...

  2. CoordinatorLayout+AppBarLayout实现上滑隐藏ToolBar-Android M新控件

    效果图 CoordinatorLayout 概述 CoordinatorLayout官方API 从官方文档中我们可以看到: CoordinatorLayout是一个增强型的FrameLayout. 两 ...

  3. NavigationDrawer和NavigationView-Android M新控件

    Translucent System Bars-4.4新特性 Toolbar-5.0新特性 NavigationDrawer 简介 NavigationDrawer 是 Google 在 Materi ...

  4. Delphi XE2 新控件 布局Panel TGridPanel TFlowPanel

    Delphi XE2 新控件 Firemonkey 布局Panel Windows平台VCl TGridPanel TFlowPanel FMX 跨平台 TLayout TGridLayout TFl ...

  5. Windows 8 开发31日-第04日-新控件

    第04日-新控件: 今天我们来学习一下基础知识--XAML程序中新增的一些控件.本文将介绍如下列出来的控件: AppBar FlipView GridView ProgressRing ScrollV ...

  6. Android5.0新控件

    谷歌在推出Android5.0的同时推出了一些新控件,Android5.0中最常用的新控件有下面5种.  1. CardView(卡片视图) CardView顾名思义是卡片视图,它继承FrameLay ...

  7. 一个Demo学会用Android兼容包新控件

    2019独角兽企业重金招聘Python工程师标准>>> 前言 伟大的Google为Android推出了一系列的兼容包,最新的就是Design Support Library了,这里我 ...

  8. 【转】Android M新控件之AppBarLayout,NavigationView,CoordinatorLayout,CollapsingToolbarLayout的使用...

    Android M新控件之AppBarLayout,NavigationView,CoordinatorLayout,CollapsingToolbarLayout的使用 分类: Android UI ...

  9. 整合TextBox与Label 创建新控件--EFLabelText

    程序开发中,经常用到一个Label 和一个TextBox组合显示数据信息,为此要频繁的拉两个控件再做适当调整,为减少类似"傻瓜"作业,而写了这个新控件--EFLabelText,其 ...

  10. UWP开发随笔——UWP新控件!AutoSuggestBox!

    UWP开发随笔--UWP新控件!AutoSuggestBox! 原文:UWP开发随笔--UWP新控件!AutoSuggestBox! 摘要 要开发一款优秀的application,控件肯定是必不可少的 ...

最新文章

  1. PotPlayer 所有版本合集
  2. 全球 Top 10 高材生赴神策数据的交流访问之旅
  3. 大数据之-Hadoop之HDFS_hadoop集群中的安全模式_原理---大数据之hadoop工作笔记0074
  4. 题解P3711:【仓鼠的数学题】
  5. 操作技巧——保障无线上网的技巧
  6. c#实现添加虚拟IP
  7. 项目管理里面的十大知识领域
  8. 智能家居设计原理c语言,基于51单片机智能家居系统设计
  9. aspose合并单元格
  10. SQL SERVER还原数据库时,如果C盘空间不足还原到其他盘的方法
  11. Tourists【广义圆方树+树链剖分+方点的特别优化】
  12. 新加坡国立计算机硕士转专业,【NUS计算机硕士毕业就业】 - 院校新闻 - 新加坡国立大学(Nus)...
  13. Incapsula-国外的免费的CDN内容分发服务
  14. mysql截取前几个字符串_mysql中截取指定字符前后的字符串
  15. 教你剪辑调整视频亮度、饱和度,一个视频调整出不同画面颜色
  16. 关于RK3288开发板的学习(1)
  17. 有若干只鸡兔同在一个笼子里,从上面数,有35个头;从下面数,有94只脚。求笼中各有几只鸡和兔?
  18. 移动安全技术如何未雨绸缪?
  19. 二维平面最短距离(分治)
  20. 强网杯2018 - nextrsa - Writeup

热门文章

  1. 2012春晚节目清单:
  2. 在CTeX上编码论文《杂谈勾股定理》及论文式样
  3. java 文件图标_如何用java程序修改文件夹默认图标,麻烦了
  4. 2020进博会霍尼韦尔特性材料和技术集团与七家企业签约项目
  5. 中移动投身开放大潮重整数据业务
  6. 怎么去掉桌面“主文件夹”图标?
  7. dcn网络与公网_DCN网络安全
  8. 软工网络15团队作业4——Alpha阶段敏捷冲刺之Scrum 冲刺博客(Day8)
  9. 幻想世界正在连接服务器,旅行物语桌面版连接不上怎么办 pc电脑版无法连接服务器怎么办...
  10. android开发apk捆绑,Android 下 APK 捆绑器的实现