code stringlengths 1 2.01M | repo_name stringlengths 3 62 | path stringlengths 1 267 | language stringclasses 231 values | license stringclasses 13 values | size int64 1 2.01M |
|---|---|---|---|---|---|
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.subactivities;
import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import es.cesar.quitesleep.R;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class About extends Activity implements OnClickListener {
private final String CLASS_NAME = getClass().getName();
private final int backButtonId = R.id.information_button_cancel;
private Button backButton;
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.about);
backButton = (Button)findViewById(backButtonId);
backButton.setOnClickListener(this);
}
public void onClick (View view) {
int viewId = view.getId();
switch (viewId) {
case backButtonId:
setResult(Activity.RESULT_CANCELED);
finish();
break;
default:
break;
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/subactivities/About.java | Java | gpl3 | 1,714 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.subactivities;
import android.app.Activity;
import android.app.Dialog;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.Toast;
import android.widget.ToggleButton;
import es.cesar.quitesleep.R;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.ddbb.Settings;
import es.cesar.quitesleep.dialogs.WarningDialog;
import es.cesar.quitesleep.operations.DialogOperations;
import es.cesar.quitesleep.operations.SmsOperations;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
import es.cesar.quitesleep.utils.QSToast;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class SmsSettings extends Activity implements OnClickListener {
final private String CLASS_NAME = getClass().getName();
final private int WARNING_DIALOG = 0;
//Ids for widgets
final int smsEditTextId = R.id.smssettings_edittext_savesms;
final int saveSmsButtonId = R.id.smssettings_button_savesms;
final int smsServiceToggleButtonId = R.id.smssettings_togglebutton_smsservice;
final int cancelButtonId = R.id.smssettings_button_cancel;
//Widgets
private EditText smsEditText;
private Button saveSmsButton;
private ToggleButton smsServiceToggleButton;
private Button cancelButton;
private WarningDialog warningDialog;
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.smssettings);
smsEditText = (EditText)findViewById(smsEditTextId);
saveSmsButton = (Button)findViewById(saveSmsButtonId);
smsServiceToggleButton = (ToggleButton)findViewById(smsServiceToggleButtonId);
cancelButton = (Button)findViewById(cancelButtonId);
saveSmsButton.setOnClickListener(this);
smsServiceToggleButton.setOnClickListener(this);
cancelButton.setOnClickListener(this);
warningDialog = new WarningDialog(
this,
ConfigAppValues.WARNING_SMS_ACTION);
//Put in the widgets the prevoious data saved into ddbb.
getDefaultValues();
}
@Override
public void onClick (View view) {
int viewId = view.getId();
switch (viewId) {
case saveSmsButtonId:
prepareSaveSmsOperation();
break;
case smsServiceToggleButtonId:
if (smsServiceToggleButton.isChecked())
showDialog(WARNING_DIALOG);
else
DialogOperations.checkSmsService(
this,
smsServiceToggleButton.isChecked());
break;
case cancelButtonId:
setResult(Activity.RESULT_CANCELED);
finish();
break;
default:
break;
}
}
/**
* Create the activity dialogs used for it
*
* @param id
* @return the dialog for the option specified
* @see Dialog
*/
@Override
protected Dialog onCreateDialog (int id) {
Dialog dialog;
switch (id) {
case WARNING_DIALOG:
if (QSLog.DEBUG_E)QSLog.d(CLASS_NAME, "Create the WarningDialog for 1st time");
dialog = warningDialog.getAlertDialog();
break;
default:
dialog = null;
}
return dialog;
}
/**
* This function prepare the dalogs every time to call for some of this
*
* @param int
* @param dialog
*/
@Override
protected void onPrepareDialog (int idDialog, Dialog dialog) {
try {
switch (idDialog) {
case WARNING_DIALOG:
warningDialog.setContext(this);
warningDialog.setToggleButtonIsChecked(smsServiceToggleButton.isChecked());
break;
default:
break;
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Put the default values saved in the ddbb in the widgets
*/
private void getDefaultValues () {
try {
ClientDDBB clientDDBB = new ClientDDBB();
Settings settings = clientDDBB.getSelects().selectSettings();
if (settings != null) {
if (settings.getSmsText()!= null && !settings.getSmsText().equals(""))
smsEditText.setText(settings.getSmsText());
smsServiceToggleButton.setChecked(settings.isSmsService());
}else {
settings = new Settings(false);
clientDDBB.getInserts().insertSettings(settings);
/* Save the sms text in the settings if the Settings object haven't
* been created, so the predefined text will be, for the moment,
* the sms text in the settings object
*/
settings.setSmsText(smsEditText.getText().toString());
clientDDBB.commit();
}
clientDDBB.close();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Function that prepare the data for save into ddbb and call to the function
* that does the operation.
*/
private void prepareSaveSmsOperation () {
try {
String smsText = smsEditText.getText().toString();
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "SmsEditText: " + smsText);
if (SmsOperations.saveSmsSettings(smsText))
if (QSToast.RELEASE) QSToast.r(
this,
this.getString(
R.string.smssettings_toast_save),
Toast.LENGTH_SHORT);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/subactivities/SmsSettings.java | Java | gpl3 | 6,359 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.subactivities;
import android.app.Activity;
import android.app.Dialog;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.Toast;
import android.widget.ToggleButton;
import es.cesar.quitesleep.R;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.ddbb.Settings;
import es.cesar.quitesleep.dialogs.WarningDialog;
import es.cesar.quitesleep.operations.DialogOperations;
import es.cesar.quitesleep.operations.MailOperations;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
import es.cesar.quitesleep.utils.QSToast;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class MailSettings extends Activity implements OnClickListener {
private final String CLASS_NAME = getClass().getName();
final private int WARNING_DIALOG = 0;
//Widgets id's
private final int userEditTextId = R.id.mailsettings_edittext_user;
private final int passwdEditTextId = R.id.mailsettings_edittext_passwd;
private final int subjectEditTextId = R.id.mailsettings_edittext_subject;
private final int bodyEditTextId = R.id.mailsettings_edittext_body;
private final int saveMailButtonId = R.id.mailsettings_button_savemail;
private final int mailServiceToggleButtonId = R.id.mailsettings_togglebutton_mailservice;
private final int cancelButtonId = R.id.mailsettings_button_cancel;
//Widgets
private EditText userEditText;
private EditText passwdEditText;
private EditText subjectEditText;
private EditText bodyEditText;
private Button saveMailButton;
private ToggleButton mailServiceToggleButton;
private Button cancelButton;
private WarningDialog warningDialog;
@Override
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.mailsettings);
//Set the widgets elements
userEditText = (EditText)findViewById(userEditTextId);
passwdEditText = (EditText)findViewById(passwdEditTextId);
subjectEditText = (EditText)findViewById(subjectEditTextId);
bodyEditText = (EditText)findViewById(bodyEditTextId);
saveMailButton = (Button)findViewById(saveMailButtonId);
mailServiceToggleButton = (ToggleButton)findViewById(mailServiceToggleButtonId);
cancelButton = (Button)findViewById(cancelButtonId);
//Set OnClickListener events
saveMailButton.setOnClickListener(this);
mailServiceToggleButton.setOnClickListener(this);
cancelButton.setOnClickListener(this);
warningDialog = new WarningDialog(
this,
ConfigAppValues.WARNING_MAIL_ACTION);
//Put in the widgets the prevoious data saved into ddbb.
getDefaultValues();
}
@Override
public void onClick (View view) {
int viewId = view.getId();
switch (viewId) {
case saveMailButtonId:
prepareSaveMailOperation();
break;
case mailServiceToggleButtonId:
if (mailServiceToggleButton.isChecked())
showDialog(WARNING_DIALOG);
else
DialogOperations.checkMailService(
this,
mailServiceToggleButton.isChecked());
break;
case cancelButtonId:
setResult(Activity.RESULT_CANCELED);
finish();
break;
default:
break;
}
}
/**
* Create the activity dialogs used for it
*
* @param id
* @return the dialog for the option specified
* @see Dialog
*/
@Override
protected Dialog onCreateDialog (int id) {
Dialog dialog;
switch (id) {
case WARNING_DIALOG:
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "Create the WarningDialog for 1st time");
dialog = warningDialog.getAlertDialog();
break;
default:
dialog = null;
}
return dialog;
}
/**
* This function prepare the dalogs every time to call for some of this
*
* @param int
* @param dialog
*/
@Override
protected void onPrepareDialog (int idDialog, Dialog dialog) {
try {
switch (idDialog) {
case WARNING_DIALOG:
warningDialog.setContext(this);
warningDialog.setToggleButtonIsChecked(mailServiceToggleButton.isChecked());
break;
default:
break;
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Function that put in the widgets the data saved into ddbb.
*/
private void getDefaultValues () {
try {
ClientDDBB clientDDBB = new ClientDDBB();
Settings settings = clientDDBB.getSelects().selectSettings();
if (settings != null) {
if (settings.getUser() != null && !settings.getUser().equals(""))
userEditText.setText(settings.getUser());
if (settings.getPasswd() != null && !settings.getPasswd().equals(""))
passwdEditText.setText(settings.getPasswd());
if (settings.getSubject() != null && !settings.getSubject().equals(""))
subjectEditText.setText(settings.getSubject());
if (settings.getBody() != null && !settings.getBody().equals(""))
bodyEditText.setText(settings.getBody());
mailServiceToggleButton.setChecked(settings.isMailService());
}
//If Settings object haven't been created previously, here we create.
else {
settings = new Settings(false);
/* Save the mail settings, only the subject and the body if the
* Settings object haven't been created for have something for
* default attributes, user and passwd not because is important
* for the mail send, and the user soon or later will have set this.
*/
settings.setSubject(subjectEditText.getText().toString());
settings.setBody(bodyEditText.getText().toString());
clientDDBB.getInserts().insertSettings(settings);
clientDDBB.commit();
}
clientDDBB.close();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Prepare all data from widgets for call to the function that save data
* into ddbb in Settings object
*
*/
private void prepareSaveMailOperation () {
try {
String user = userEditText.getText().toString();
String passwd = passwdEditText.getText().toString();
String subject = subjectEditText.getText().toString();
String body = bodyEditText.getText().toString();
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "user: " + user);
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "passwd: " + passwd);
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "subject: " + subject);
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "body: " + body);
if (MailOperations.saveMailSettings(user, passwd, subject, body))
//All right, start the service was ok!
if (QSToast.RELEASE) QSToast.r(
this,
this.getString(
R.string.mailsettings_toast_save),
Toast.LENGTH_SHORT);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/subactivities/MailSettings.java | Java | gpl3 | 7,988 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.subactivities;
import java.util.ArrayList;
import java.util.List;
import android.app.Activity;
import android.app.Dialog;
import android.app.ListActivity;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.util.Log;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.widget.ArrayAdapter;
import android.widget.ListView;
import android.widget.Toast;
import es.cesar.quitesleep.R;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.ddbb.Contact;
import es.cesar.quitesleep.dialogs.WarningDialog;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
import es.cesar.quitesleep.utils.QSToast;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
* @version 0.1, 03-13-2010
*
* Class for AddContacts to the banned user list
*
*/
public class AddBanned extends ListActivity {
//Constants
final private String CLASS_NAME = this.getClass().getName();
final private int WARNING_DIALOG = 0;
//Widgets Id's
final private int addAllMenuId = R.id.menu_addall;
//Widgets
private WarningDialog warningDialog;
private ArrayAdapter<String> arrayAdapter;
//Auxiliar attributes
private String selectContactName;
/**
* onCreate
*
* @param savedInstanceState
*/
@Override
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
warningDialog = new WarningDialog(
this,
ConfigAppValues.WARNING_ADD_ALL_CONTACTS);
getAllContactList();
}
/**
* Get all not banned contacts from the database and parse it for create
* one contact list only with their contactNames
*/
private void getAllContactList () {
try {
ClientDDBB clientDDBB = new ClientDDBB();
List<Contact> contactList = clientDDBB.getSelects().selectAllNotBannedContacts();
List<String> contactListString = convertContactList(contactList);
if (contactListString != null) {
arrayAdapter = new ArrayAdapter<String>(
this,
R.layout.addbanned,
R.id.addBanned_textview_name,
contactListString);
setListAdapter(arrayAdapter);
}
clientDDBB.close();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
*
* @param contactList
* @return The contactList but only the list with the name contacts
* @see List<String>
*/
private List<String> convertContactList (List<Contact> contactList) throws Exception {
try {
if (contactList != null && contactList.size()>0) {
List<String> contactListString = new ArrayList<String>();
for (int i=0; i<contactList.size(); i++) {
String contactName = contactList.get(i).getContactName();
if (contactName != null)
contactListString.add(contactName);
}
return contactListString;
}
return null;
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
throw new Exception();
}
}
@Override
protected void onListItemClick (
ListView listView,
View view,
int position,
long id){
try {
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "OnListItemClick");
super.onListItemClick(listView, view, position, id);
selectContactName = (String) this.getListAdapter().getItem(position);
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "Name: " + selectContactName);
/* If we like to use one subactivity for show better contact details
* and select what phone number and/or mail addresses are used for
* send busy response.
*/
Intent intentContactDetails = new Intent(this,ContactDetails.class);
intentContactDetails.putExtra(ConfigAppValues.CONTACT_NAME, selectContactName);
startActivityForResult(intentContactDetails, ConfigAppValues.REQCODE_CONTACT_DETAILS);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
@Override
public void onActivityResult (int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
switch(requestCode) {
case ConfigAppValues.REQCODE_CONTACT_DETAILS:
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "Valor retornado: " + resultCode);
if (resultCode == Activity.RESULT_OK)
arrayAdapter.remove(selectContactName);
break;
default:
break;
}
}
/**
* Create the activity dialogs used for it
*
* @param id
* @return the dialog for the option specified
* @see Dialog
*/
@Override
protected Dialog onCreateDialog (int id) {
Dialog dialog;
switch (id) {
case WARNING_DIALOG:
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "Create the WarningDialog for 1st time");
dialog = warningDialog.getAlertDialog();
break;
default:
dialog = null;
}
return dialog;
}
/**
* This function prepare the dalogs every time to call for some of this
*
* @param int
* @param dialog
*/
@Override
protected void onPrepareDialog (int idDialog, Dialog dialog) {
try {
switch (idDialog) {
case WARNING_DIALOG:
warningDialog.setContext(this);
warningDialog.setArrayAdapter(arrayAdapter);
warningDialog.setHandler(handler);
break;
default:
break;
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
@Override
public boolean onCreateOptionsMenu (Menu menu) {
try {
MenuInflater menuInflater = getMenuInflater();
menuInflater.inflate(R.menu.addallmenu, menu);
return true;
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
return false;
}
}
/**
* @param item
* @return boolean
*/
@Override
public boolean onOptionsItemSelected (MenuItem item) {
try {
switch (item.getItemId()) {
case addAllMenuId:
showDialog(WARNING_DIALOG);
break;
default:
break;
}
return false;
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
return false;
}
}
/**
* Handler for clear the listView and the array adapter once we have been
* add all contacts to the banned list
*/
public final Handler handler = new Handler() {
public void handleMessage(Message message) {
final String NUM_BANNED = "NUM_BANNED";
if (arrayAdapter != null && arrayAdapter.getCount()>0) {
//int count = arrayAdapter.getCount();
int numBanned = message.getData().getInt(NUM_BANNED);
//clear the arrayAdapter
arrayAdapter.clear();
//Show the toast message
if (QSToast.RELEASE) QSToast.r(
ConfigAppValues.getContext(),
numBanned + " " + ConfigAppValues.getContext().getString(
R.string.menu_addall_toast_insertscount),
Toast.LENGTH_SHORT);
}
}
};
}
| 120301csr038-description | src/es/cesar/quitesleep/subactivities/AddBanned.java | Java | gpl3 | 8,333 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.subactivities;
import java.util.ArrayList;
import java.util.List;
import android.app.Activity;
import android.graphics.Typeface;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.LinearLayout;
import android.widget.ScrollView;
import android.widget.TextView;
import android.widget.Toast;
import es.cesar.quitesleep.R;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.ddbb.Contact;
import es.cesar.quitesleep.ddbb.Mail;
import es.cesar.quitesleep.ddbb.Phone;
import es.cesar.quitesleep.operations.ContactOperations;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
import es.cesar.quitesleep.utils.QSToast;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class ContactDetails extends Activity implements OnClickListener {
final private String CLASS_NAME = getClass().getName();
//Global widgets
private ScrollView scrollView;
private LinearLayout linearLayout;
//Phone and mail list for dynamic checkbox
private List<CheckBox> phoneCheckboxList;
private List<CheckBox> mailCheckboxList;
/* The contact Name selected in parent and caller activity when the user
* selectd clicking in it.
*/
private String selectContactName;
//Ids for button widgets
private final int addContactButtonId = 1;
private final int cancelButtonId = 2;
//Ids for colors
private final int backgroundColor = R.color.black;
private final int textColor = R.color.black;
@Override
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
initDynamicLayout();
}
/**
* Create and initialize the dynamic layout and put some widgets on it
*/
private void initDynamicLayout () {
try {
/* Get the contactName passed from the parent activity to this, and
* use for get a Contact object refferenced to this name.
*/
selectContactName = getIntent().getExtras().getString(
ConfigAppValues.CONTACT_NAME);
ClientDDBB clientDDBB = new ClientDDBB();
Contact contact = clientDDBB.getSelects().selectContactForName(selectContactName);
if (contact != null && !contact.isBanned()) {
if (QSLog.DEBUG_D)QSLog.d(
CLASS_NAME, "selectContactName: " + selectContactName);
createLayout();
createHeader();
createPhoneNumbersSection(clientDDBB, contact);
createMailAddressesSection(clientDDBB, contact);
addButtons();
setContentView(scrollView);
clientDDBB.close();
}else {
clientDDBB.close();
setResult(Activity.RESULT_CANCELED);
finish();
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/*
* Create the scrollView and LinearLayput for put some widgets on it
*/
private void createLayout () {
try {
scrollView = new ScrollView(this);
linearLayout = new LinearLayout(this);
linearLayout.setOrientation(LinearLayout.VERTICAL);
scrollView.setBackgroundColor(this.getResources().getColor(backgroundColor));
scrollView.addView(linearLayout);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Put the contactName and a separator view how header for the layout
*/
private void createHeader () {
try {
TextView contactName = new TextView(this);
contactName.setText(selectContactName);
//contactName.setTextColor(textColor);
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(
LinearLayout.LayoutParams.FILL_PARENT,
LinearLayout.LayoutParams.FILL_PARENT);
contactName.setLayoutParams(params);
contactName.setTypeface(Typeface.create("", Typeface.BOLD_ITALIC));
contactName.setTextSize(25);
linearLayout.addView(contactName);
addDividerBlack();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Create the phone numbers section
*
* @param clientDDBB
* @param contact
*/
private void createPhoneNumbersSection (ClientDDBB clientDDBB, Contact contact) {
try {
List<Phone> contactPhones =
clientDDBB.getSelects().selectAllContactPhonesForName(selectContactName);
if (contactPhones != null) {
addDividerDetails(R.string.contactdetails_label_phonedetails);
phoneCheckboxList = new ArrayList<CheckBox>(contactPhones.size());
for (int i=0; i<contactPhones.size(); i++) {
Phone phone = contactPhones.get(i);
CheckBox checkbox = new CheckBox(this);
checkbox.setText(phone.getContactPhone());
checkbox.setChecked(phone.isUsedToSend());
//checkbox.setTextColor(textColor);
linearLayout.addView(checkbox);
phoneCheckboxList.add(checkbox);
}
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Create the mail addresses section
*
* @param clientDDBB
* @param contact
*/
private void createMailAddressesSection (ClientDDBB clientDDBB, Contact contact) {
try {
List<Mail> contactMails =
clientDDBB.getSelects().selectAllContactMailsForName(selectContactName);
if (contactMails != null && contactMails.size() > 0) {
addDividerDetails(R.string.contactdetails_label_maildetails);
mailCheckboxList = new ArrayList<CheckBox>(contactMails.size());
for (int i=0; i<contactMails.size(); i++) {
Mail mail = contactMails.get(i);
CheckBox checkbox = new CheckBox(this);
checkbox.setText(mail.getContactMail());
checkbox.setChecked(mail.isUsedToSend());
//checkbox.setTextColor(textColor);
linearLayout.addView(checkbox);
mailCheckboxList.add(checkbox);
}
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Put one black dividerDetails view in the layout.
* Pass the resId with the string that we like it.
* @param resId
*/
private void addDividerDetails (int resId) {
TextView details = new TextView(this);
details.setBackgroundResource(R.drawable.solid_black);
details.setTypeface(Typeface.create("", Typeface.BOLD));
details.setTextSize(15);
details.setText(resId);
details.setPadding(0, 10, 0, 0);
linearLayout.addView(details);
}
/**
* Put one black divider view in the layout as separator for other views
*/
private void addDividerBlack () {
TextView dividerBlack = new TextView(this);
dividerBlack.setBackgroundResource(R.drawable.gradient_black);
dividerBlack.setTextSize(3);
linearLayout.addView(dividerBlack);
}
/**
* Put one blue divider view in the layout as separator for other views
*/
private void addDividerBlue () {
TextView dividerBlue = new TextView(this);
dividerBlue.setBackgroundResource(R.drawable.gradient_blue);
dividerBlue.setTextSize(2);
linearLayout.addView(dividerBlue);
}
/**
* Put two buttons, one for addContact to the banned list and other for
* cancel and go back to the parent activity.
*/
private void addButtons () {
try {
addDividerBlack();
Button addContactButton = new Button(this);
addContactButton.setText(R.string.contactdetails_button_addcontact);
addContactButton.setId(addContactButtonId);
addContactButton.setCompoundDrawablesWithIntrinsicBounds(R.drawable.add, 0, 0, 0);
addContactButton.setId(addContactButtonId);
addContactButton.setOnClickListener(this);
linearLayout.addView(addContactButton);
addDividerBlue();
Button cancelButton = new Button(this);
cancelButton.setText(R.string.contactdetails_button_cancel);
cancelButton.setId(cancelButtonId);
cancelButton.setCompoundDrawablesWithIntrinsicBounds(R.drawable.back, 0, 0, 0);
cancelButton.setId(cancelButtonId);
cancelButton.setOnClickListener(this);
linearLayout.addView(cancelButton);
}catch (Exception e) {
if (QSLog.DEBUG_E)Log.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
@Override
public void onClick (View view) {
try {
int viewId = view.getId();
switch (viewId) {
case addContactButtonId:
boolean result = ContactOperations.addContact(
selectContactName,
phoneCheckboxList,
mailCheckboxList);
showToast(result);
setResult(Activity.RESULT_OK);
finish();
break;
case cancelButtonId:
setResult(Activity.RESULT_CANCELED);
finish();
break;
default:
break;
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Show toast notification for information to user
*
* @param result
*/
private void showToast (boolean result) {
try {
if (result)
if (QSToast.RELEASE) QSToast.r(
this,
this.getString(
R.string.contactdetails_toast_added),
Toast.LENGTH_SHORT);
else
if (QSToast.RELEASE) QSToast.r(
this,
this.getString(
R.string.contactdetails_toast_fail),
Toast.LENGTH_SHORT);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/subactivities/ContactDetails.java | Java | gpl3 | 10,943 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.subactivities;
import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import es.cesar.quitesleep.R;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class Help extends Activity implements OnClickListener{
private final String CLASS_NAME = getClass().getName();
private final int backButtonId = R.id.information_button_cancel;
private Button backButton;
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.help);
backButton = (Button)findViewById(backButtonId);
backButton.setOnClickListener(this);
}
public void onClick (View view) {
int viewId = view.getId();
switch (viewId) {
case backButtonId:
setResult(Activity.RESULT_CANCELED);
finish();
break;
default:
break;
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/subactivities/Help.java | Java | gpl3 | 1,713 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.subactivities;
import java.util.ArrayList;
import java.util.List;
import android.app.Activity;
import android.graphics.Typeface;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.CheckBox;
import android.widget.LinearLayout;
import android.widget.ScrollView;
import android.widget.TextView;
import android.widget.Toast;
import es.cesar.quitesleep.R;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.ddbb.Contact;
import es.cesar.quitesleep.ddbb.Mail;
import es.cesar.quitesleep.ddbb.Phone;
import es.cesar.quitesleep.operations.ContactOperations;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
import es.cesar.quitesleep.utils.QSToast;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class EditContact extends Activity implements OnClickListener {
final private String CLASS_NAME = getClass().getName();
//Global widgets
private ScrollView scrollView;
private LinearLayout linearLayout;
//Phone and mail list for dynamic checkbox
private List<CheckBox> phoneCheckboxList;
private List<CheckBox> mailCheckboxList;
/* The contact Name selected in parent and caller activity when the user
* selectd clicking in it.
*/
private String selectContactName;
//Ids for button widgets
private final int removeContactButtonId = 1;
private final int editContactButtonId = 2;
private final int cancelButtonId = 3;
//Ids for colors
private final int backgroundColor = R.color.black;
private final int textColor = R.color.black;
@Override
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
initDynamicLayout();
}
/**
* Create and initialize the dynamic layout and put some widgets on it
*/
private void initDynamicLayout () {
try {
/* Get the contactName passed from the parent activity to this, and
* use for get a Contact object refferenced to this name.
*/
selectContactName = getIntent().getExtras().getString(ConfigAppValues.CONTACT_NAME);
ClientDDBB clientDDBB = new ClientDDBB();
Contact contact = clientDDBB.getSelects().selectContactForName(selectContactName);
if (contact != null && contact.isBanned()) {
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "selectContactName: " + selectContactName);
createLayout();
createHeader();
createPhoneNumbersSection(clientDDBB, contact);
createMailAddressesSection(clientDDBB, contact);
addButtons();
setContentView(scrollView);
clientDDBB.close();
}else {
clientDDBB.close();
setResult(Activity.RESULT_CANCELED);
finish();
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/*
* Create the scrollView and LinearLayput for put some widgets on it
*/
private void createLayout () {
try {
scrollView = new ScrollView(this);
linearLayout = new LinearLayout(this);
linearLayout.setOrientation(LinearLayout.VERTICAL);
scrollView.setBackgroundColor(this.getResources().getColor(backgroundColor));
scrollView.addView(linearLayout);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Put the contactName and a separator view how header for the layout
*/
private void createHeader () {
try {
TextView contactName = new TextView(this);
contactName.setText(selectContactName);
//contactName.setTextColor(textColor);
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(
LinearLayout.LayoutParams.FILL_PARENT,
LinearLayout.LayoutParams.FILL_PARENT);
contactName.setLayoutParams(params);
contactName.setTypeface(Typeface.create("", Typeface.BOLD_ITALIC));
contactName.setTextSize(25);
linearLayout.addView(contactName);
addDividerBlack();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Create the phone numbers section
*
* @param clientDDBB
* @param contact
*/
private void createPhoneNumbersSection (ClientDDBB clientDDBB, Contact contact) {
try {
List<Phone> contactPhones =
clientDDBB.getSelects().selectAllContactPhonesForName(selectContactName);
if (contactPhones != null) {
addDividerDetails(R.string.contactdetails_label_phonedetails);
phoneCheckboxList = new ArrayList<CheckBox>(contactPhones.size());
for (int i=0; i<contactPhones.size(); i++) {
Phone phone = contactPhones.get(i);
CheckBox checkbox = new CheckBox(this);
checkbox.setText(phone.getContactPhone());
checkbox.setChecked(phone.isUsedToSend());
//checkbox.setTextColor(textColor);
linearLayout.addView(checkbox);
phoneCheckboxList.add(checkbox);
}
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Create the mail addresses section
*
* @param clientDDBB
* @param contact
*/
private void createMailAddressesSection (ClientDDBB clientDDBB, Contact contact) {
try {
List<Mail> contactMails =
clientDDBB.getSelects().selectAllContactMailsForName(selectContactName);
if (contactMails != null && contactMails.size() > 0) {
addDividerDetails(R.string.contactdetails_label_maildetails);
mailCheckboxList = new ArrayList<CheckBox>(contactMails.size());
for (int i=0; i<contactMails.size(); i++) {
Mail mail = contactMails.get(i);
CheckBox checkbox = new CheckBox(this);
checkbox.setText(mail.getContactMail());
checkbox.setChecked(mail.isUsedToSend());
//checkbox.setTextColor(textColor);
linearLayout.addView(checkbox);
mailCheckboxList.add(checkbox);
}
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Put one black dividerDetails view in the layout.
* Pass the resId with the string that we like it.
* @param resId
*/
private void addDividerDetails (int resId) {
TextView details = new TextView(this);
details.setBackgroundResource(R.drawable.solid_black);
details.setTypeface(Typeface.create("", Typeface.BOLD));
details.setTextSize(15);
details.setText(resId);
details.setPadding(0, 10, 0, 0);
linearLayout.addView(details);
}
/**
* Put one black divider view in the layout as separator for other views
*/
private void addDividerBlack () {
TextView dividerBlack = new TextView(this);
dividerBlack.setBackgroundResource(R.drawable.gradient_black);
dividerBlack.setTextSize(3);
linearLayout.addView(dividerBlack);
}
/**
* Put one blue divider view in the layout as separator for other views
*/
private void addDividerBlue () {
TextView dividerBlue = new TextView(this);
dividerBlue.setBackgroundResource(R.drawable.gradient_blue);
dividerBlue.setTextSize(2);
linearLayout.addView(dividerBlue);
}
/**
* Put two buttons, one for addContact to the banned list and other for
* cancel and go back to the parent activity.
*/
private void addButtons () {
try {
addDividerBlack();
Button editButton = new Button(this);
editButton.setText(R.string.editcontact_button_edit);
editButton.setId(editContactButtonId);
editButton.setCompoundDrawablesWithIntrinsicBounds(R.drawable.edit, 0, 0, 0);
editButton.setId(editContactButtonId);
editButton.setOnClickListener(this);
linearLayout.addView(editButton);
addDividerBlue();
Button removeContactButton = new Button(this);
removeContactButton.setText(R.string.editcontact_button_remove);
removeContactButton.setId(removeContactButtonId);
removeContactButton.setCompoundDrawablesWithIntrinsicBounds(R.drawable.delete, 0, 0, 0);
removeContactButton.setId(removeContactButtonId);
removeContactButton.setOnClickListener(this);
linearLayout.addView(removeContactButton);
addDividerBlue();
Button cancelButton = new Button(this);
cancelButton.setText(R.string.contactdetails_button_cancel);
cancelButton.setId(cancelButtonId);
cancelButton.setCompoundDrawablesWithIntrinsicBounds(R.drawable.back, 0, 0, 0);
cancelButton.setId(cancelButtonId);
cancelButton.setOnClickListener(this);
linearLayout.addView(cancelButton);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
@Override
public void onClick (View view) {
try {
int viewId = view.getId();
boolean result;
switch (viewId) {
case editContactButtonId:
result = ContactOperations.editContact(
selectContactName,
phoneCheckboxList,
mailCheckboxList);
showEditToast(result);
break;
case removeContactButtonId:
result = ContactOperations.removeContact(selectContactName);
showRemoveToast(result);
setResult(Activity.RESULT_OK);
finish();
break;
case cancelButtonId:
setResult(Activity.RESULT_CANCELED);
finish();
break;
default:
break;
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Show toast notification for information to user
*
* @param result
*/
private void showEditToast (boolean result) {
try {
if (result)
if (QSToast.RELEASE) QSToast.r(
this,
this.getString(
R.string.editcontact_toast_edit),
Toast.LENGTH_SHORT);
else
if (QSToast.RELEASE) QSToast.r(
this,
this.getString(
R.string.editcontact_toast_edit_fail),
Toast.LENGTH_SHORT);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Show notification toast to the user for information.
*
* @param result
*/
private void showRemoveToast (boolean result) {
try {
if (result)
if (QSToast.RELEASE) QSToast.r(
this,
this.getString(
R.string.editcontact_toast_remove),
Toast.LENGTH_SHORT);
else
if (QSToast.RELEASE) QSToast.r(
this,
this.getString(
R.string.editcontact_toast_remove_fail),
Toast.LENGTH_SHORT);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/subactivities/EditContact.java | Java | gpl3 | 12,283 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.subactivities;
import java.util.ArrayList;
import java.util.List;
import android.app.Activity;
import android.app.Dialog;
import android.app.ListActivity;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.util.Log;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.widget.ArrayAdapter;
import android.widget.ListView;
import android.widget.Toast;
import es.cesar.quitesleep.R;
import es.cesar.quitesleep.ddbb.Banned;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.dialogs.WarningDialog;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
import es.cesar.quitesleep.utils.QSToast;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class DeleteBanned extends ListActivity {
//Constants
final private String CLASS_NAME = this.getClass().getName();
final private int WARNING_DIALOG = 0;
//Widgets Ids
private final int removeAllMenuId = R.id.menu_removeall;
//Widgets
private WarningDialog warningDialog;
private ArrayAdapter<String> arrayAdapter;
//Attributes
private String selectContactName;
@Override
public void onCreate (Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
warningDialog = new WarningDialog(
this,
ConfigAppValues.WARNING_REMOVE_ALL_CONTACTS);
getAllContactList();
}
/**
* Get all banned contact list from the database
*/
private void getAllContactList () {
try {
ClientDDBB clientDDBB = new ClientDDBB();
List<Banned> contactList = clientDDBB.getSelects().selectAllBannedContacts();
List<String> contactListString = convertContactList(contactList);
if (contactListString != null) {
arrayAdapter = new ArrayAdapter<String>(
this,
R.layout.deletebanned,
R.id.deleteBanned_textview_name,
contactListString);
setListAdapter(arrayAdapter);
}
clientDDBB.close();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
/**
* Function that convert all banned contact list in Contact objects to
* one List<String> with only the contact name attribute.
*
* @param contactList
* @return The contactList but only the list with the name contacts
* @see List<String>
*/
private List<String> convertContactList (List<Banned> bannedList) throws Exception {
try {
if (bannedList != null && bannedList.size()>0) {
List<String> bannedListString = new ArrayList<String>(bannedList.size());
for (int i=0; i<bannedList.size(); i++) {
Banned banned = bannedList.get(i);
String contactName = banned.getContact().getContactName();
if (contactName == null)
contactName = "";
bannedListString.add(contactName);
}
return bannedListString;
}
return null;
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
throw new Exception();
}
}
@Override
protected void onListItemClick (
ListView listView,
View view,
int position,
long id){
try {
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "OnListItemClick");
super.onListItemClick(listView, view, position, id);
selectContactName = (String) this.getListAdapter().getItem(position);
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "Name: " + selectContactName);
/* If we like to use one subactivity for show better contact details
* and edit what phone number and/or mail addresses are used for
* send busy response, and remove contact from banned list.
*/
Intent intentEditContact = new Intent(this, EditContact.class);
intentEditContact.putExtra(ConfigAppValues.CONTACT_NAME, selectContactName);
startActivityForResult(intentEditContact, ConfigAppValues.REQCODE_EDIT_CONTACT);
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
@Override
public void onActivityResult (int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
switch(requestCode) {
case ConfigAppValues.REQCODE_EDIT_CONTACT:
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "Valor retornado: " + resultCode);
if (resultCode == Activity.RESULT_OK)
arrayAdapter.remove(selectContactName);
break;
default:
break;
}
}
/**
* Create the activity dialogs used for it
*
* @param id
* @return the dialog for the option specified
* @see Dialog
*/
@Override
protected Dialog onCreateDialog (int id) {
Dialog dialog;
switch (id) {
case WARNING_DIALOG:
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "Create the AlertDialog for 1st time");
dialog = warningDialog.getAlertDialog();
break;
default:
dialog = null;
}
return dialog;
}
/**
* This function prepare the dalogs every time to call for some of this
*
* @param int
* @param dialog
*/
@Override
protected void onPrepareDialog (int idDialog, Dialog dialog) {
try {
switch (idDialog) {
case WARNING_DIALOG:
warningDialog.setContext(this);
warningDialog.setArrayAdapter(arrayAdapter);
warningDialog.setHandler(handler);
break;
default:
break;
}
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}
}
@Override
public boolean onCreateOptionsMenu (Menu menu) {
try {
MenuInflater menuInflater = getMenuInflater();
menuInflater.inflate(R.menu.removeallmenu, menu);
return true;
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
return false;
}
}
/**
* @param item
* @return boolean
*/
@Override
public boolean onOptionsItemSelected (MenuItem item) {
try {
switch (item.getItemId()) {
case removeAllMenuId:
showDialog(WARNING_DIALOG);
break;
default:
break;
}
return false;
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
return false;
}
}
/**
* Handler for clear the listView and the array adapter once we have been
* add all contacts to the banned list
*/
public final Handler handler = new Handler() {
public void handleMessage(Message message) {
if (arrayAdapter != null && arrayAdapter.getCount()>0) {
//int count = arrayAdapter.getCount();
int numRemoveContacts = message.getData().getInt(
ConfigAppValues.NUM_REMOVE_CONTACTS);
//clear the arrayAdapter
arrayAdapter.clear();
//Show the toast message
if (QSToast.RELEASE) QSToast.r(
ConfigAppValues.getContext(),
numRemoveContacts + " " + ConfigAppValues.getContext().getString(
R.string.menu_removeall_toast_removecount),
Toast.LENGTH_SHORT);
}
}
};
}
| 120301csr038-description | src/es/cesar/quitesleep/subactivities/DeleteBanned.java | Java | gpl3 | 8,335 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.menus;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.util.Log;
import android.widget.ArrayAdapter;
import es.cesar.quitesleep.ddbb.Banned;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.ddbb.Contact;
import es.cesar.quitesleep.ddbb.Schedule;
import es.cesar.quitesleep.dialogs.AddAllDialog;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class AddAllMenu extends Thread {
private final String CLASS_NAME = getClass().getName();
private ArrayAdapter<String> arrayAdapter = null;
private AddAllDialog addAllDialog;
private Handler handler;
//------------- Getters & Setters ------------------------------//
public ArrayAdapter<String> getArrayAdapter() {
return arrayAdapter;
}
public void setArrayAdapter(ArrayAdapter<String> arrayAdapter) {
this.arrayAdapter = arrayAdapter;
}
//------------------------------------------------------------------------//
/**
* Constructor with the basic parameter
*
* @param arrayAdapter
* @param addAllDialog
* @param handler
*/
public AddAllMenu (
ArrayAdapter<String> arrayAdapter,
AddAllDialog addAllDialog,
Handler handler) {
this.arrayAdapter = arrayAdapter;
this.addAllDialog = addAllDialog;
this.handler = handler;
}
public void run () {
addAll();
}
/**
* Add to the banned list all contacts of the listview (arrayadapter)
*
*/
private void addAll () {
final String NUM_BANNED = "NUM_BANNED";
int numBanend = 0;
try {
ClientDDBB clientDDBB = new ClientDDBB();
Schedule schedule = clientDDBB.getSelects().selectSchedule();
if (schedule != null) {
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "size list: " + arrayAdapter.getCount());
//while (arrayAdapter.getCount()>0) {
for (int i=0; i<arrayAdapter.getCount(); i++) {
/* all time we get the first element (0) of the list
* because when we remove the actual element at the final code
* the next element put to the first position, and so with all.
*/
String contactName = arrayAdapter.getItem(i);
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "añadiendo: " + contactName);
if (contactName != null && !contactName.equals("")) {
Contact contact =
clientDDBB.getSelects().selectContactForName(contactName);
if (contact != null) {
Banned banned = new Banned(contact, schedule);
contact.setBanned(true);
clientDDBB.getUpdates().insertContact(contact);
clientDDBB.getInserts().insertBanned(banned);
numBanend ++;
}
}
}
clientDDBB.commit();
}
clientDDBB.close();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}finally {
//Hide and dismiss de synchronization dialog
addAllDialog.stopDialog(ConfigAppValues.getContext());
//Create and send the numBanned message to the handler in gui main thread
Message message = handler.obtainMessage();
Bundle bundle = new Bundle();
bundle.putInt(NUM_BANNED, numBanend);
message.setData(bundle);
handler.sendMessage(message);
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/menus/AddAllMenu.java | Java | gpl3 | 4,291 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.menus;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.util.Log;
import android.widget.ArrayAdapter;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.dialogs.CallLogDialog;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class RemoveCallLogMenu extends Thread {
private final String CLASS_NAME = getClass().getName();
private ArrayAdapter<String> arrayAdapter = null;
private CallLogDialog callLogDialog;
private Handler handler;
//------------- Getters & Setters ------------------------------//
public ArrayAdapter<String> getArrayAdapter() {
return arrayAdapter;
}
public void setArrayAdapter(ArrayAdapter<String> arrayAdapter) {
this.arrayAdapter = arrayAdapter;
}
//------------------------------------------------------------------------//
/**
* Constructor with the basic parameter
*
* @param arrayAdapter
* @param callLogDialog
* @param handler
*/
public RemoveCallLogMenu (
ArrayAdapter<String> arrayAdapter,
CallLogDialog callLogDialog,
Handler handler) {
this.arrayAdapter = arrayAdapter;
this.callLogDialog = callLogDialog;
this.handler = handler;
}
public void run () {
removeAll();
}
/**
* Remove all callLog objects from the ddbb and the list
*/
private void removeAll () {
int numRemoveCallLogs = 0;
try {
ClientDDBB clientDDBB = new ClientDDBB();
numRemoveCallLogs = clientDDBB.getDeletes().deleteAllCallLog();
clientDDBB.commit();
clientDDBB.close();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}finally {
//Hide and dismiss de synchronization dialog
callLogDialog.stopDialog(ConfigAppValues.getContext());
//Create and send the numBanned message to the handler in gui main thread
Message message = handler.obtainMessage();
Bundle bundle = new Bundle();
bundle.putInt(ConfigAppValues.NUM_REMOVE_CALL_LOGS, numRemoveCallLogs);
message.setData(bundle);
handler.sendMessage(message);
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/menus/RemoveCallLogMenu.java | Java | gpl3 | 3,150 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.menus;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.util.Log;
import android.widget.ArrayAdapter;
import es.cesar.quitesleep.ddbb.Banned;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.ddbb.Contact;
import es.cesar.quitesleep.dialogs.RemoveAllDialog;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class RemoveAllMenu extends Thread {
private final String CLASS_NAME = getClass().getName();
private ArrayAdapter<String> arrayAdapter = null;
private RemoveAllDialog removeAllDialog;
private Handler handler;
//------------- Getters & Setters ------------------------------//
public ArrayAdapter<String> getArrayAdapter() {
return arrayAdapter;
}
public void setArrayAdapter(ArrayAdapter<String> arrayAdapter) {
this.arrayAdapter = arrayAdapter;
}
//------------------------------------------------------------------------//
/**
* Constructor with the basic parameter
*
* @param arrayAdapter
* @param removeAllDialog
* @param handler
*/
public RemoveAllMenu (
ArrayAdapter<String> arrayAdapter,
RemoveAllDialog removeAllDialog,
Handler handler) {
this.arrayAdapter = arrayAdapter;
this.removeAllDialog = removeAllDialog;
this.handler = handler;
}
public void run () {
removeAll();
}
/**
* Remove all contacts from the banned list
*/
private void removeAll () {
int numRemoveContacts = 0;
try {
ClientDDBB clientDDBB = new ClientDDBB();
//while (arrayAdapter.getCount() > 0) {
for (int i=0; i<arrayAdapter.getCount(); i++) {
String contactName = arrayAdapter.getItem(i);
if (contactName != null && !contactName.equals("")) {
Banned banned =
clientDDBB.getSelects().selectBannedContactForName(contactName);
if (banned != null) {
Contact contact = banned.getContact();
contact.setBanned(false);
clientDDBB.getUpdates().insertContact(contact);
clientDDBB.getDeletes().deleteBanned(banned);
numRemoveContacts ++;
}
}
}
clientDDBB.commit();
clientDDBB.close();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}finally {
//Hide and dismiss de synchronization dialog
removeAllDialog.stopDialog(ConfigAppValues.getContext());
//Create and send the numBanned message to the handler in gui main thread
Message message = handler.obtainMessage();
Bundle bundle = new Bundle();
bundle.putInt(ConfigAppValues.NUM_REMOVE_CONTACTS, numRemoveContacts);
message.setData(bundle);
handler.sendMessage(message);
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/menus/RemoveAllMenu.java | Java | gpl3 | 3,748 |
/*
Copyright 2010 Cesar Valiente Gordo
This file is part of QuiteSleep.
QuiteSleep is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
QuiteSleep is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with QuiteSleep. If not, see <http://www.gnu.org/licenses/>.
*/
package es.cesar.quitesleep.menus;
import java.util.ArrayList;
import java.util.List;
import android.os.Bundle;
import android.os.Handler;
import android.os.Message;
import android.util.Log;
import android.widget.ArrayAdapter;
import es.cesar.quitesleep.ddbb.CallLog;
import es.cesar.quitesleep.ddbb.ClientDDBB;
import es.cesar.quitesleep.dialogs.CallLogDialog;
import es.cesar.quitesleep.staticValues.ConfigAppValues;
import es.cesar.quitesleep.utils.ExceptionUtils;
import es.cesar.quitesleep.utils.QSLog;
/**
*
* @author Cesar Valiente Gordo
* @mail cesar.valiente@gmail.com
*
*/
public class RefreshCallLogMenu extends Thread {
private final String CLASS_NAME = getClass().getName();
private ArrayAdapter<String> arrayAdapter = null;
private CallLogDialog callLogDialog;
private Handler handler;
//------------- Getters & Setters ------------------------------//
public ArrayAdapter<String> getArrayAdapter() {
return arrayAdapter;
}
public void setArrayAdapter(ArrayAdapter<String> arrayAdapter) {
this.arrayAdapter = arrayAdapter;
}
//------------------------------------------------------------------------//
/**
* Constructor with the basic parameter
*
* @param arrayAdapter
* @param callLogDialog
* @param handler
*/
public RefreshCallLogMenu (
ArrayAdapter<String> arrayAdapter,
CallLogDialog callLogDialog,
Handler handler) {
this.arrayAdapter = arrayAdapter;
this.callLogDialog = callLogDialog;
this.handler = handler;
}
public void run () {
refreshAll();
}
/**
* Remove all callLog objects from the ddbb and the list
*/
private void refreshAll () {
ArrayList<String> callLogListString = null;
try {
ClientDDBB clientDDBB = new ClientDDBB();
List<CallLog> callLogList = clientDDBB.getSelects().selectAllCallLog();
if (QSLog.DEBUG_D)QSLog.d(CLASS_NAME, "Call log list: " + callLogList);
if (callLogList != null) {
callLogListString = new ArrayList<String>(callLogList.size());
for (int i=0; i<callLogList.size(); i++) {
String callLog = callLogList.get(i).toString();
callLogListString.add(callLog);
}
}
clientDDBB.close();
}catch (Exception e) {
if (QSLog.DEBUG_E)QSLog.e(CLASS_NAME, ExceptionUtils.exceptionTraceToString(
e.toString(),
e.getStackTrace()));
}finally {
//Hide and dismiss de synchronization dialog
callLogDialog.stopDialog(ConfigAppValues.getContext());
//Create and send the numBanned message to the handler in gui main thread
Message message = handler.obtainMessage();
Bundle bundle = new Bundle();
bundle.putStringArrayList(ConfigAppValues.REFRESH_CALL_LOG, callLogListString);
message.setData(bundle);
handler.sendMessage(message);
}
}
}
| 120301csr038-description | src/es/cesar/quitesleep/menus/RefreshCallLogMenu.java | Java | gpl3 | 3,602 |
/* Javadoc style sheet */
/* Define colors, fonts and other style attributes here to override the defaults */
/* Page background color */
body { background-color: #FFFFFF; color:#000000 }
/* Headings */
h1 { font-size: 145% }
/* Table colors */
.TableHeadingColor { background: #CCCCFF; color:#000000 } /* Dark mauve */
.TableSubHeadingColor { background: #EEEEFF; color:#000000 } /* Light mauve */
.TableRowColor { background: #FFFFFF; color:#000000 } /* White */
/* Font used in left-hand frame lists */
.FrameTitleFont { font-size: 100%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
.FrameHeadingFont { font-size: 90%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
.FrameItemFont { font-size: 90%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
/* Navigation bar fonts and colors */
.NavBarCell1 { background-color:#EEEEFF; color:#000000} /* Light mauve */
.NavBarCell1Rev { background-color:#00008B; color:#FFFFFF} /* Dark Blue */
.NavBarFont1 { font-family: Arial, Helvetica, sans-serif; color:#000000;color:#000000;}
.NavBarFont1Rev { font-family: Arial, Helvetica, sans-serif; color:#FFFFFF;color:#FFFFFF;}
.NavBarCell2 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF; color:#000000}
.NavBarCell3 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF; color:#000000}
| 120301csr038-description | doc/stylesheet.css | CSS | gpl3 | 1,391 |
<!doctype html>
<html lang="us">
<head>
<meta charset="utf-8">
<title>jQuery UI Example Page</title>
<link href="css/ui-lightness/jquery-ui-1.9.1.custom.css" rel="stylesheet">
<script src="js/jquery-1.8.2.js"></script>
<script src="js/jquery-ui-1.9.1.custom.js"></script>
<script>
$(function() {
$( "#accordion" ).accordion();
var availableTags = [
"ActionScript",
"AppleScript",
"Asp",
"BASIC",
"C",
"C++",
"Clojure",
"COBOL",
"ColdFusion",
"Erlang",
"Fortran",
"Groovy",
"Haskell",
"Java",
"JavaScript",
"Lisp",
"Perl",
"PHP",
"Python",
"Ruby",
"Scala",
"Scheme"
];
$( "#autocomplete" ).autocomplete({
source: availableTags
});
$( "#button" ).button();
$( "#radioset" ).buttonset();
$( "#tabs" ).tabs();
$( "#dialog" ).dialog({
autoOpen: false,
width: 400,
buttons: [
{
text: "Ok",
click: function() {
$( this ).dialog( "close" );
}
},
{
text: "Cancel",
click: function() {
$( this ).dialog( "close" );
}
}
]
});
// Link to open the dialog
$( "#dialog-link" ).click(function( event ) {
$( "#dialog" ).dialog( "open" );
event.preventDefault();
});
$( "#datepicker" ).datepicker({
inline: true
});
$( "#slider" ).slider({
range: true,
values: [ 17, 67 ]
});
$( "#progressbar" ).progressbar({
value: 20
});
// Hover states on the static widgets
$( "#dialog-link, #icons li" ).hover(
function() {
$( this ).addClass( "ui-state-hover" );
},
function() {
$( this ).removeClass( "ui-state-hover" );
}
);
});
</script>
<style>
body{
font: 62.5% "Trebuchet MS", sans-serif;
margin: 50px;
}
.demoHeaders {
margin-top: 2em;
}
#dialog-link {
padding: .4em 1em .4em 20px;
text-decoration: none;
position: relative;
}
#dialog-link span.ui-icon {
margin: 0 5px 0 0;
position: absolute;
left: .2em;
top: 50%;
margin-top: -8px;
}
#icons {
margin: 0;
padding: 0;
}
#icons li {
margin: 2px;
position: relative;
padding: 4px 0;
cursor: pointer;
float: left;
list-style: none;
}
#icons span.ui-icon {
float: left;
margin: 0 4px;
}
</style>
</head>
<body>
<h1>Welcome to jQuery UI!</h1>
<div class="ui-widget">
<p>This page demonstrates the widgets you downloaded using the theme you selected in the download builder. We've included and linked to minified versions of <a href="js/jquery-1.8.2.js">jQuery</a>, your personalized copy of <a href="js/jquery-ui-1.9.1.custom.min.js">jQuery UI (js/jquery-ui-1.9.1.custom.min.js)</a>, and <a href="css/ui-lightness/jquery-ui-1.9.1.custom.min.css">css/ui-lightness/jquery-ui-1.9.1.custom.min.css</a> which imports the entire jQuery UI CSS Framework. You can choose to link a subset of the CSS Framework depending on your needs. </p>
<p>You've downloaded components and a theme that are compatible with jQuery 1.6+. Please make sure you are using jQuery 1.6+ in your production environment.</p>
</div>
<h1>YOUR COMPONENTS:</h1>
<!-- Accordion -->
<h2 class="demoHeaders">Accordion</h2>
<div id="accordion">
<h3>First</h3>
<div>Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet.</div>
<h3>Second</h3>
<div>Phasellus mattis tincidunt nibh.</div>
<h3>Third</h3>
<div>Nam dui erat, auctor a, dignissim quis.</div>
</div>
<!-- Autocomplete -->
<h2 class="demoHeaders">Autocomplete</h2>
<div>
<input id="autocomplete" title="type "a"">
</div>
<!-- Button -->
<h2 class="demoHeaders">Button</h2>
<button id="button">A button element</button>
<form style="margin-top: 1em;">
<div id="radioset">
<input type="radio" id="radio1" name="radio"><label for="radio1">Choice 1</label>
<input type="radio" id="radio2" name="radio" checked="checked"><label for="radio2">Choice 2</label>
<input type="radio" id="radio3" name="radio"><label for="radio3">Choice 3</label>
</div>
</form>
<!-- Tabs -->
<h2 class="demoHeaders">Tabs</h2>
<div id="tabs">
<ul>
<li><a href="#tabs-1">First</a></li>
<li><a href="#tabs-2">Second</a></li>
<li><a href="#tabs-3">Third</a></li>
</ul>
<div id="tabs-1">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</div>
<div id="tabs-2">Phasellus mattis tincidunt nibh. Cras orci urna, blandit id, pretium vel, aliquet ornare, felis. Maecenas scelerisque sem non nisl. Fusce sed lorem in enim dictum bibendum.</div>
<div id="tabs-3">Nam dui erat, auctor a, dignissim quis, sollicitudin eu, felis. Pellentesque nisi urna, interdum eget, sagittis et, consequat vestibulum, lacus. Mauris porttitor ullamcorper augue.</div>
</div>
<!-- Dialog NOTE: Dialog is not generated by UI in this demo so it can be visually styled in themeroller-->
<h2 class="demoHeaders">Dialog</h2>
<p><a href="#" id="dialog-link" class="ui-state-default ui-corner-all"><span class="ui-icon ui-icon-newwin"></span>Open Dialog</a></p>
<h2 class="demoHeaders">Overlay and Shadow Classes <em>(not currently used in UI widgets)</em></h2>
<div style="position: relative; width: 96%; height: 200px; padding:1% 2%; overflow:hidden;" class="fakewindowcontain">
<p>Lorem ipsum dolor sit amet, Nulla nec tortor. Donec id elit quis purus consectetur consequat. </p><p>Nam congue semper tellus. Sed erat dolor, dapibus sit amet, venenatis ornare, ultrices ut, nisi. Aliquam ante. Suspendisse scelerisque dui nec velit. Duis augue augue, gravida euismod, vulputate ac, facilisis id, sem. Morbi in orci. </p><p>Nulla purus lacus, pulvinar vel, malesuada ac, mattis nec, quam. Nam molestie scelerisque quam. Nullam feugiat cursus lacus.orem ipsum dolor sit amet, consectetur adipiscing elit. Donec libero risus, commodo vitae, pharetra mollis, posuere eu, pede. Nulla nec tortor. Donec id elit quis purus consectetur consequat. </p><p>Nam congue semper tellus. Sed erat dolor, dapibus sit amet, venenatis ornare, ultrices ut, nisi. Aliquam ante. Suspendisse scelerisque dui nec velit. Duis augue augue, gravida euismod, vulputate ac, facilisis id, sem. Morbi in orci. Nulla purus lacus, pulvinar vel, malesuada ac, mattis nec, quam. Nam molestie scelerisque quam. </p><p>Nullam feugiat cursus lacus.orem ipsum dolor sit amet, consectetur adipiscing elit. Donec libero risus, commodo vitae, pharetra mollis, posuere eu, pede. Nulla nec tortor. Donec id elit quis purus consectetur consequat. Nam congue semper tellus. Sed erat dolor, dapibus sit amet, venenatis ornare, ultrices ut, nisi. Aliquam ante. </p><p>Suspendisse scelerisque dui nec velit. Duis augue augue, gravida euismod, vulputate ac, facilisis id, sem. Morbi in orci. Nulla purus lacus, pulvinar vel, malesuada ac, mattis nec, quam. Nam molestie scelerisque quam. Nullam feugiat cursus lacus.orem ipsum dolor sit amet, consectetur adipiscing elit. Donec libero risus, commodo vitae, pharetra mollis, posuere eu, pede. Nulla nec tortor. Donec id elit quis purus consectetur consequat. Nam congue semper tellus. Sed erat dolor, dapibus sit amet, venenatis ornare, ultrices ut, nisi. </p>
<!-- ui-dialog -->
<div class="ui-overlay"><div class="ui-widget-overlay"></div><div class="ui-widget-shadow ui-corner-all" style="width: 302px; height: 152px; position: absolute; left: 50px; top: 30px;"></div></div>
<div style="position: absolute; width: 280px; height: 130px;left: 50px; top: 30px; padding: 10px;" class="ui-widget ui-widget-content ui-corner-all">
<div class="ui-dialog-content ui-widget-content" style="background: none; border: 0;">
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>
</div>
</div>
</div>
<!-- ui-dialog -->
<div id="dialog" title="Dialog Title">
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>
</div>
<h2 class="demoHeaders">Framework Icons (content color preview)</h2>
<ul id="icons" class="ui-widget ui-helper-clearfix">
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-1-n"><span class="ui-icon ui-icon-carat-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-1-ne"><span class="ui-icon ui-icon-carat-1-ne"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-1-e"><span class="ui-icon ui-icon-carat-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-1-se"><span class="ui-icon ui-icon-carat-1-se"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-1-s"><span class="ui-icon ui-icon-carat-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-1-sw"><span class="ui-icon ui-icon-carat-1-sw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-1-w"><span class="ui-icon ui-icon-carat-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-1-nw"><span class="ui-icon ui-icon-carat-1-nw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-2-n-s"><span class="ui-icon ui-icon-carat-2-n-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-carat-2-e-w"><span class="ui-icon ui-icon-carat-2-e-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-1-n"><span class="ui-icon ui-icon-triangle-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-1-ne"><span class="ui-icon ui-icon-triangle-1-ne"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-1-e"><span class="ui-icon ui-icon-triangle-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-1-se"><span class="ui-icon ui-icon-triangle-1-se"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-1-s"><span class="ui-icon ui-icon-triangle-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-1-sw"><span class="ui-icon ui-icon-triangle-1-sw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-1-w"><span class="ui-icon ui-icon-triangle-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-1-nw"><span class="ui-icon ui-icon-triangle-1-nw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-2-n-s"><span class="ui-icon ui-icon-triangle-2-n-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-triangle-2-e-w"><span class="ui-icon ui-icon-triangle-2-e-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-1-n"><span class="ui-icon ui-icon-arrow-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-1-ne"><span class="ui-icon ui-icon-arrow-1-ne"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-1-e"><span class="ui-icon ui-icon-arrow-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-1-se"><span class="ui-icon ui-icon-arrow-1-se"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-1-s"><span class="ui-icon ui-icon-arrow-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-1-sw"><span class="ui-icon ui-icon-arrow-1-sw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-1-w"><span class="ui-icon ui-icon-arrow-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-1-nw"><span class="ui-icon ui-icon-arrow-1-nw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-2-n-s"><span class="ui-icon ui-icon-arrow-2-n-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-2-ne-sw"><span class="ui-icon ui-icon-arrow-2-ne-sw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-2-e-w"><span class="ui-icon ui-icon-arrow-2-e-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-2-se-nw"><span class="ui-icon ui-icon-arrow-2-se-nw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowstop-1-n"><span class="ui-icon ui-icon-arrowstop-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowstop-1-e"><span class="ui-icon ui-icon-arrowstop-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowstop-1-s"><span class="ui-icon ui-icon-arrowstop-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowstop-1-w"><span class="ui-icon ui-icon-arrowstop-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-1-n"><span class="ui-icon ui-icon-arrowthick-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-1-ne"><span class="ui-icon ui-icon-arrowthick-1-ne"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-1-e"><span class="ui-icon ui-icon-arrowthick-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-1-se"><span class="ui-icon ui-icon-arrowthick-1-se"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-1-s"><span class="ui-icon ui-icon-arrowthick-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-1-sw"><span class="ui-icon ui-icon-arrowthick-1-sw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-1-w"><span class="ui-icon ui-icon-arrowthick-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-1-nw"><span class="ui-icon ui-icon-arrowthick-1-nw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-2-n-s"><span class="ui-icon ui-icon-arrowthick-2-n-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-2-ne-sw"><span class="ui-icon ui-icon-arrowthick-2-ne-sw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-2-e-w"><span class="ui-icon ui-icon-arrowthick-2-e-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthick-2-se-nw"><span class="ui-icon ui-icon-arrowthick-2-se-nw"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthickstop-1-n"><span class="ui-icon ui-icon-arrowthickstop-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthickstop-1-e"><span class="ui-icon ui-icon-arrowthickstop-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthickstop-1-s"><span class="ui-icon ui-icon-arrowthickstop-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowthickstop-1-w"><span class="ui-icon ui-icon-arrowthickstop-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowreturnthick-1-w"><span class="ui-icon ui-icon-arrowreturnthick-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowreturnthick-1-n"><span class="ui-icon ui-icon-arrowreturnthick-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowreturnthick-1-e"><span class="ui-icon ui-icon-arrowreturnthick-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowreturnthick-1-s"><span class="ui-icon ui-icon-arrowreturnthick-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowreturn-1-w"><span class="ui-icon ui-icon-arrowreturn-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowreturn-1-n"><span class="ui-icon ui-icon-arrowreturn-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowreturn-1-e"><span class="ui-icon ui-icon-arrowreturn-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowreturn-1-s"><span class="ui-icon ui-icon-arrowreturn-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowrefresh-1-w"><span class="ui-icon ui-icon-arrowrefresh-1-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowrefresh-1-n"><span class="ui-icon ui-icon-arrowrefresh-1-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowrefresh-1-e"><span class="ui-icon ui-icon-arrowrefresh-1-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrowrefresh-1-s"><span class="ui-icon ui-icon-arrowrefresh-1-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-4"><span class="ui-icon ui-icon-arrow-4"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-arrow-4-diag"><span class="ui-icon ui-icon-arrow-4-diag"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-extlink"><span class="ui-icon ui-icon-extlink"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-newwin"><span class="ui-icon ui-icon-newwin"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-refresh"><span class="ui-icon ui-icon-refresh"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-shuffle"><span class="ui-icon ui-icon-shuffle"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-transfer-e-w"><span class="ui-icon ui-icon-transfer-e-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-transferthick-e-w"><span class="ui-icon ui-icon-transferthick-e-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-folder-collapsed"><span class="ui-icon ui-icon-folder-collapsed"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-folder-open"><span class="ui-icon ui-icon-folder-open"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-document"><span class="ui-icon ui-icon-document"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-document-b"><span class="ui-icon ui-icon-document-b"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-note"><span class="ui-icon ui-icon-note"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-mail-closed"><span class="ui-icon ui-icon-mail-closed"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-mail-open"><span class="ui-icon ui-icon-mail-open"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-suitcase"><span class="ui-icon ui-icon-suitcase"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-comment"><span class="ui-icon ui-icon-comment"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-person"><span class="ui-icon ui-icon-person"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-print"><span class="ui-icon ui-icon-print"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-trash"><span class="ui-icon ui-icon-trash"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-locked"><span class="ui-icon ui-icon-locked"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-unlocked"><span class="ui-icon ui-icon-unlocked"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-bookmark"><span class="ui-icon ui-icon-bookmark"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-tag"><span class="ui-icon ui-icon-tag"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-home"><span class="ui-icon ui-icon-home"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-flag"><span class="ui-icon ui-icon-flag"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-calculator"><span class="ui-icon ui-icon-calculator"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-cart"><span class="ui-icon ui-icon-cart"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-pencil"><span class="ui-icon ui-icon-pencil"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-clock"><span class="ui-icon ui-icon-clock"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-disk"><span class="ui-icon ui-icon-disk"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-calendar"><span class="ui-icon ui-icon-calendar"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-zoomin"><span class="ui-icon ui-icon-zoomin"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-zoomout"><span class="ui-icon ui-icon-zoomout"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-search"><span class="ui-icon ui-icon-search"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-wrench"><span class="ui-icon ui-icon-wrench"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-gear"><span class="ui-icon ui-icon-gear"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-heart"><span class="ui-icon ui-icon-heart"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-star"><span class="ui-icon ui-icon-star"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-link"><span class="ui-icon ui-icon-link"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-cancel"><span class="ui-icon ui-icon-cancel"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-plus"><span class="ui-icon ui-icon-plus"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-plusthick"><span class="ui-icon ui-icon-plusthick"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-minus"><span class="ui-icon ui-icon-minus"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-minusthick"><span class="ui-icon ui-icon-minusthick"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-close"><span class="ui-icon ui-icon-close"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-closethick"><span class="ui-icon ui-icon-closethick"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-key"><span class="ui-icon ui-icon-key"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-lightbulb"><span class="ui-icon ui-icon-lightbulb"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-scissors"><span class="ui-icon ui-icon-scissors"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-clipboard"><span class="ui-icon ui-icon-clipboard"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-copy"><span class="ui-icon ui-icon-copy"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-contact"><span class="ui-icon ui-icon-contact"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-image"><span class="ui-icon ui-icon-image"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-video"><span class="ui-icon ui-icon-video"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-script"><span class="ui-icon ui-icon-script"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-alert"><span class="ui-icon ui-icon-alert"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-info"><span class="ui-icon ui-icon-info"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-notice"><span class="ui-icon ui-icon-notice"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-help"><span class="ui-icon ui-icon-help"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-check"><span class="ui-icon ui-icon-check"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-bullet"><span class="ui-icon ui-icon-bullet"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-radio-off"><span class="ui-icon ui-icon-radio-off"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-radio-on"><span class="ui-icon ui-icon-radio-on"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-pin-w"><span class="ui-icon ui-icon-pin-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-pin-s"><span class="ui-icon ui-icon-pin-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-play"><span class="ui-icon ui-icon-play"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-pause"><span class="ui-icon ui-icon-pause"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-seek-next"><span class="ui-icon ui-icon-seek-next"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-seek-prev"><span class="ui-icon ui-icon-seek-prev"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-seek-end"><span class="ui-icon ui-icon-seek-end"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-seek-first"><span class="ui-icon ui-icon-seek-first"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-stop"><span class="ui-icon ui-icon-stop"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-eject"><span class="ui-icon ui-icon-eject"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-volume-off"><span class="ui-icon ui-icon-volume-off"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-volume-on"><span class="ui-icon ui-icon-volume-on"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-power"><span class="ui-icon ui-icon-power"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-signal-diag"><span class="ui-icon ui-icon-signal-diag"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-signal"><span class="ui-icon ui-icon-signal"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-battery-0"><span class="ui-icon ui-icon-battery-0"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-battery-1"><span class="ui-icon ui-icon-battery-1"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-battery-2"><span class="ui-icon ui-icon-battery-2"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-battery-3"><span class="ui-icon ui-icon-battery-3"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-plus"><span class="ui-icon ui-icon-circle-plus"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-minus"><span class="ui-icon ui-icon-circle-minus"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-close"><span class="ui-icon ui-icon-circle-close"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-triangle-e"><span class="ui-icon ui-icon-circle-triangle-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-triangle-s"><span class="ui-icon ui-icon-circle-triangle-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-triangle-w"><span class="ui-icon ui-icon-circle-triangle-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-triangle-n"><span class="ui-icon ui-icon-circle-triangle-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-arrow-e"><span class="ui-icon ui-icon-circle-arrow-e"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-arrow-s"><span class="ui-icon ui-icon-circle-arrow-s"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-arrow-w"><span class="ui-icon ui-icon-circle-arrow-w"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-arrow-n"><span class="ui-icon ui-icon-circle-arrow-n"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-zoomin"><span class="ui-icon ui-icon-circle-zoomin"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-zoomout"><span class="ui-icon ui-icon-circle-zoomout"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circle-check"><span class="ui-icon ui-icon-circle-check"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circlesmall-plus"><span class="ui-icon ui-icon-circlesmall-plus"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circlesmall-minus"><span class="ui-icon ui-icon-circlesmall-minus"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-circlesmall-close"><span class="ui-icon ui-icon-circlesmall-close"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-squaresmall-plus"><span class="ui-icon ui-icon-squaresmall-plus"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-squaresmall-minus"><span class="ui-icon ui-icon-squaresmall-minus"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-squaresmall-close"><span class="ui-icon ui-icon-squaresmall-close"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-grip-dotted-vertical"><span class="ui-icon ui-icon-grip-dotted-vertical"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-grip-dotted-horizontal"><span class="ui-icon ui-icon-grip-dotted-horizontal"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-grip-solid-vertical"><span class="ui-icon ui-icon-grip-solid-vertical"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-grip-solid-horizontal"><span class="ui-icon ui-icon-grip-solid-horizontal"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-gripsmall-diagonal-se"><span class="ui-icon ui-icon-gripsmall-diagonal-se"></span></li>
<li class="ui-state-default ui-corner-all" title=".ui-icon-grip-diagonal-se"><span class="ui-icon ui-icon-grip-diagonal-se"></span></li>
</ul>
<!-- Slider -->
<h2 class="demoHeaders">Slider</h2>
<div id="slider"></div>
<!-- Datepicker -->
<h2 class="demoHeaders">Datepicker</h2>
<div id="datepicker"></div>
<!-- Progressbar -->
<h2 class="demoHeaders">Progressbar</h2>
<div id="progressbar"></div>
<!-- Highlight / Error -->
<h2 class="demoHeaders">Highlight / Error</h2>
<div class="ui-widget">
<div class="ui-state-highlight ui-corner-all" style="margin-top: 20px; padding: 0 .7em;">
<p><span class="ui-icon ui-icon-info" style="float: left; margin-right: .3em;"></span>
<strong>Hey!</strong> Sample ui-state-highlight style.</p>
</div>
</div>
<br>
<div class="ui-widget">
<div class="ui-state-error ui-corner-all" style="padding: 0 .7em;">
<p><span class="ui-icon ui-icon-alert" style="float: left; margin-right: .3em;"></span>
<strong>Alert:</strong> Sample ui-state-error style.</p>
</div>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/index.html | HTML | bsd | 31,372 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI autocomplete documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Autocomplete Widget",
"excerpt":
"Autocomplete enables users to quickly find and select from a pre-populated list of values as they type, leveraging searching and filtering.",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-appendTo">appendTo</a></div>
<div><a href="#option-autoFocus">autoFocus</a></div>
<div><a href="#option-delay">delay</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-minLength">minLength</a></div>
<div><a href="#option-position">position</a></div>
<div><a href="#option-source">source</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-close">close</a></div>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-search">search</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-change">change</a></div>
<div><a href="#event-close">close</a></div>
<div><a href="#event-create">create</a></div>
<div><a href="#event-focus">focus</a></div>
<div><a href="#event-open">open</a></div>
<div><a href="#event-response">response</a></div>
<div><a href="#event-search">search</a></div>
<div><a href="#event-select">select</a></div>
</div></section><article id="autocomplete1" class="entry widget"><h2 class="section-title">
<span>Autocomplete Widget</span><span class="version-details">version added: 1.8</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Autocomplete enables users to quickly find and select from a pre-populated list of values as they type, leveraging searching and filtering.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-appendTo" class="api-item first-item">
<h3>appendTo<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"body"</code>
</div>
<div>Which element the menu should be appended to. Override this when the autocomplete is inside a <code>position: fixed</code> element. Otherwise the popup menu would still scroll with the page.</div>
<strong>Code examples:</strong><p>Initialize the autocomplete with the appendTo option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete({ appendTo: </code><code class="string">"#someElem"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the appendTo option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">appendTo = $( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"appendTo"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"appendTo"</code><code class="plain">, </code><code class="string">"#someElem"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-autoFocus" class="api-item">
<h3>autoFocus<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If set to <code>true</code> the first item will automatically be focused when the menu is shown.</div>
<strong>Code examples:</strong><p>Initialize the autocomplete with the autoFocus option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete({ autoFocus: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the autoFocus option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">autoFocus = $( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"autoFocus"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"autoFocus"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-delay" class="api-item">
<h3>delay<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>300</code>
</div>
<div>The delay in milliseconds between when a keystroke occurs and when a search is performed. A zero-delay makes sense for local data (more responsive), but can produce a lot of load for remote data, while being less responsive.</div>
<strong>Code examples:</strong><p>Initialize the autocomplete with the delay option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete({ delay: 500 });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the delay option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">delay = $( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"delay"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"delay"</code><code class="plain">, 500 );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the autocomplete if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the autocomplete with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-minLength" class="api-item">
<h3>minLength<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1</code>
</div>
<div>The minimum number of characters a user must type before a search is performed. Zero is useful for local data with just a few items, but a higher value should be used when a single character search could match a few thousand items.</div>
<strong>Code examples:</strong><p>Initialize the autocomplete with the minLength option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete({ minLength: 0 });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the minLength option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">minLength = $( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"minLength"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"minLength"</code><code class="plain">, 0 );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-position" class="api-item">
<h3>position<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{ my: "left top", at: "left bottom", collision: "none" }</code>
</div>
<div>Identifies the position of the suggestions menu in relation to the associated input element. The <code>of</code> option defaults to the input element, but you can specify another element to position against. You can refer to the <a href="/position">jQuery UI Position</a> utility for more details about the various options.</div>
<strong>Code examples:</strong><p>Initialize the autocomplete with the position option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete({ position: { my : </code><code class="string">"right top"</code><code class="plain">, at: </code><code class="string">"right bottom"</code> <code class="plain">} });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the position option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">position = $( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"position"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"position"</code><code class="plain">, { my : </code><code class="string">"right top"</code><code class="plain">, at: </code><code class="string">"right bottom"</code> <code class="plain">} );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-source" class="api-item">
<h3>source<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types/#Function">Function</a>( <a href="http://api.jquery.com/Types#Object">Object</a> request, <a href="http://api.jquery.com/Types#Function">Function</a> response( <a href="http://api.jquery.com/Types#Object">Object</a> data ) )</span>
</h3>
<div class="default">
<strong>Default: </strong><code>none; must be specified</code>
</div>
<div>
Defines the data to use, must be specified.
<p>Independent of the variant you use, the label is always treated as text. If you want the label to be treated as html you can use <a href="https://github.com/scottgonzalez/jquery-ui-extensions/blob/master/autocomplete/jquery.ui.autocomplete.html.js">Scott González' html extension</a>. The demos all focus on different variations of the <code>source</code> option - look for one that matches your use case, and check out the code.</p>
</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Array</strong>:
An array can be used for local data. There are two supported formats:
<ul>
<li>An array of strings: <code>[ "Choice1", "Choice2" ]</code>
</li>
<li>An array of objects with <code>label</code> and <code>value</code> properties: <code>[ { label: "Choice1", value: "value1" }, ... ]</code>
</li>
</ul>
The label property is displayed in the suggestion menu. The value will be inserted into the input element when a user selects an item. If just one property is specified, it will be used for both, e.g., if you provide only <code>value</code> properties, the value will also be used as the label.
</li>
<li>
<strong>String</strong>: When a string is used, the Autocomplete plugin expects that string to point to a URL resource that will return JSON data. It can be on the same host or on a different one (must provide JSONP). The Autocomplete plugin does not filter the results, instead a query string is added with a <code>term</code> field, which the server-side script should use for filtering the results. For example, if the <code>source</code> option is set to <code>"http://example.com"</code> and the user types <code>foo</code>, a GET request would be made to <code>http://example.com?term=foo</code>. The data itself can be in the same format as the local data described above.</li>
<li>
<strong>Function</strong>:
The third variation, a callback, provides the most flexibility and can be used to connect any data source to Autocomplete. The callback gets two arguments:
<ul>
<li>A <code>request</code> object, with a single <code>term</code> property, which refers to the value currently in the text input. For example, if the user enters <code>"new yo"</code> in a city field, the Autocomplete term will equal <code>"new yo"</code>.</li>
<li>A <code>response</code> callback, which expects a single argument: the data to suggest to the user. This data should be filtered based on the provided term, and can be in any of the formats described above for simple local data. It's important when providing a custom source callback to handle errors during the request. You must always call the <code>response</code> callback even if you encounter an error. This ensures that the widget always has the correct state.</li>
</ul>
<p>When filtering data locally, you can make use of the built-in <code>$.ui.autocomplete.escapeRegex</code> function. It'll take a single string argument and escape all regex characters, making the result safe to pass to <code>new RegExp()</code>.</p>
</li>
</ul>
<strong>Code examples:</strong><p>Initialize the autocomplete with the source option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete({ source: [ </code><code class="string">"c++"</code><code class="plain">, </code><code class="string">"java"</code><code class="plain">, </code><code class="string">"php"</code><code class="plain">, </code><code class="string">"coldfusion"</code><code class="plain">, </code><code class="string">"javascript"</code><code class="plain">, </code><code class="string">"asp"</code><code class="plain">, </code><code class="string">"ruby"</code> <code class="plain">] });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the source option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">source = $( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"source"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).autocomplete( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"source"</code><code class="plain">, [ </code><code class="string">"c++"</code><code class="plain">, </code><code class="string">"java"</code><code class="plain">, </code><code class="string">"php"</code><code class="plain">, </code><code class="string">"coldfusion"</code><code class="plain">, </code><code class="string">"javascript"</code><code class="plain">, </code><code class="string">"asp"</code><code class="plain">, </code><code class="string">"ruby"</code> <code class="plain">] );</code></div></div></td></tr></tbody></table></div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-close"><div class="api-item first-item">
<h3>close()</h3>
<div>Closes the Autocomplete menu. Useful in combination with the <a href="#method-search"><code>search</code></a> method, to close the open menu.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-destroy"><div class="api-item">
<h3>destroy()</h3>
<div>
Removes the autocomplete functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the autocomplete.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the autocomplete.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current autocomplete options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the autocomplete option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the autocomplete.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-search"><div class="api-item">
<h3>search( [value ] )</h3>
<div>Triggers a <a href="#event-search"><code>search</code></a> event and invokes the data source if the event is not canceled. Can be used by a selectbox-like button to open the suggestions when clicked. When invoked with no parameters, the current input's value is used. Can be called with an empty string and <code>minLength: 0</code> to display all items.</div>
<ul><li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div></div>
</li></ul>
</div></div>
<div id="method-widget"><div class="api-item">
<h3>widget()</h3>
<div>Returns a <code>jQuery</code> object containing the menu element. Although the menu items are constantly created and destroyed, the menu element itself is created during initialization and is constantly reused.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-change" class="api-item first-item">
<h3>change( event, ui )</h3>
<div>Triggered when the field is blurred, if the value has changed.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The item selected from the menu, if any. Otherwise the property is <code>null</code>.</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-close" class="api-item">
<h3>close( event, ui )</h3>
<div>Triggered when the menu is hidden. Not every <code>close</code> event will be accompanied by a <code>change</code> event.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the autocomplete is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-focus" class="api-item">
<h3>focus( event, ui )</h3>
<div>
Triggered when focus is moved to an item (not selecting). The default action is to replace the text field's value with the value of the focused item, though only if the event was triggered by a keyboard interaction.
<p>Canceling this event prevents the value from being updated, but does not prevent the menu item from being focused.</p>
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The focused item.</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-open" class="api-item">
<h3>open( event, ui )</h3>
<div>Triggered when the suggestion menu is opened or updated.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-response" class="api-item">
<h3>response( event, ui )</h3>
<div>Triggered after a search completes, before the menu is shown. Useful for local manipulation of suggestion data, where a custom <a href="#option-source"><code>source</code></a> option callback is not required. This event is always triggered when a search completes, even if the menu will not be shown because there are no results or the Autocomplete is disabled.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>content</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Array">Array</a>
</div>
<div>Contains the response data and can be modified to change the results that will be shown. This data is already normalized, so if you modify the data, make sure to include both <code>value</code> and <code>label</code> properties for each item.</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-search" class="api-item">
<h3>search( event, ui )</h3>
<div>Triggered before a search is performed, after <a href="#option-minLength"><code>minLength</code></a> and <a href="#option-delay"><code>delay</code></a> are met. If canceled, then no request will be started and no items suggested.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-select" class="api-item">
<h3>select( event, ui )</h3>
<div>
Triggered when an item is selected from the menu. The default action is to replace the text field's value with the value of the selected item.
<p>Canceling this event prevents the value from being updated, but does not prevent the menu from closing.</p>
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The selected item.</div>
</li></ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>By giving an Autocomplete field focus or entering something into it, the plugin starts searching for entries that match and displays a list of values to choose from. By entering more characters, the user can filter down the list to better matches.</p>
<p>This can be used to choose previously selected values, such as entering tags for articles or entering email addresses from an address book. Autocomplete can also be used to populate associated information, such as entering a city name and getting the zip code.</p>
<p>You can pull data in from a local or remote source: Local is good for small data sets, e.g., an address book with 50 entries; remote is necessary for big data sets, such as a database with hundreds or millions of entries to select from. To find out more about customizing the data soure, see the documentation for the <a href="#option-source"><code>source</code></a> option.</p>
<h3>Keyboard interaction</h3>
<p>When the menu is open, the following key commands are available:</p>
<ul>
<li>UP - Move focus to the previous item. If on first item, move focus to the input. If on the input, move focus to last item.</li>
<li>DOWN - Move focus to the next item. If on last item, move focus to the input. If on the input, move focus to the first item.</li>
<li>ESCAPE - Close the menu.</li>
<li>ENTER - Select the currently focused item and close the menu.</li>
<li>TAB - Select the currently focused item, close the menu, and move focus to the next focusable element.</li>
<li>PAGE UP/DOWN - Scroll through a page of items (based on height of menu). <em>It's generally a bad idea to display so many items that users need to page.</em>.</li>
</ul>
<p>When the menu is closed, the following key commands are available:</p>
<ul>
<li>UP/DOWN - Open the menu, if the <a href="#option-minLength"><code>minLength</code></a> has been met.</li>
</ul>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Examples:</h2></header><div class="entry-example" id="example-0">
<h4>Example: <span class="desc">A simple jQuery UI Autocomplete</span>
</h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>autocomplete demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">label</code> <code class="color1">for</code><code class="plain">=</code><code class="string">"autocomplete"</code><code class="plain">>Select a programming language: </</code><code class="keyword">label</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="plain"><</code><code class="keyword">input</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"autocomplete"</code><code class="plain">></code></div><div class="line number14 index13 alt1"> </div><div class="line number15 index14 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain">$( "#autocomplete" ).autocomplete({</code></div><div class="line number17 index16 alt2"><code class="undefined spaces"> </code><code class="plain">source: [ "c++", "java", "php", "coldfusion", "javascript", "asp", "ruby" ]</code></div><div class="line number18 index17 alt1"><code class="plain">});</code></div><div class="line number19 index18 alt2"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number20 index19 alt1"> </div><div class="line number21 index20 alt2"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number22 index21 alt1"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div>
<div class="entry-example" id="example-1">
<h4>Example: <span class="desc">Using a custom source callback to match only the beginning of terms</span>
</h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>autocomplete demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">label</code> <code class="color1">for</code><code class="plain">=</code><code class="string">"autocomplete"</code><code class="plain">>Select a programming language: </</code><code class="keyword">label</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="plain"><</code><code class="keyword">input</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"autocomplete"</code><code class="plain">></code></div><div class="line number14 index13 alt1"> </div><div class="line number15 index14 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain">var tags = [ "c++", "java", "php", "coldfusion", "javascript", "asp", "ruby" ];</code></div><div class="line number17 index16 alt2"><code class="plain">$( "#autocomplete" ).autocomplete({</code></div><div class="line number18 index17 alt1"><code class="undefined spaces"> </code><code class="plain">source: function( request, response ) {</code></div><div class="line number19 index18 alt2"><code class="undefined spaces"> </code><code class="plain">var matcher = new RegExp( "^" + $.ui.autocomplete.escapeRegex( request.term ), "i" );</code></div><div class="line number20 index19 alt1"><code class="undefined spaces"> </code><code class="plain">response( $.grep( tags, function( item ){</code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain">return matcher.test( item );</code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain">}) );</code></div><div class="line number23 index22 alt2"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number24 index23 alt1"><code class="plain">});</code></div><div class="line number25 index24 alt2"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number26 index25 alt1"> </div><div class="line number27 index26 alt2"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/autocomplete.html | HTML | bsd | 46,023 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI selectable documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Selectable Widget",
"excerpt":
"Use the mouse to select elements, individually or in a group.",
"termSlugs": {
"category": [
"interactions"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-autoRefresh">autoRefresh</a></div>
<div><a href="#option-cancel">cancel</a></div>
<div><a href="#option-delay">delay</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-distance">distance</a></div>
<div><a href="#option-filter">filter</a></div>
<div><a href="#option-tolerance">tolerance</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-refresh">refresh</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
<div><a href="#event-selected">selected</a></div>
<div><a href="#event-selecting">selecting</a></div>
<div><a href="#event-start">start</a></div>
<div><a href="#event-stop">stop</a></div>
<div><a href="#event-unselected">unselected</a></div>
<div><a href="#event-unselecting">unselecting</a></div>
</div></section><article id="selectable1" class="entry widget"><h2 class="section-title">
<span>Selectable Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Use the mouse to select elements, individually or in a group.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-autoRefresh" class="api-item first-item">
<h3>autoRefresh<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>This determines whether to refresh (recalculate) the position and size of each selectee at the beginning of each select operation. If you have many items, you may want to set this to false and call the <a href="#method-refresh"><code>refresh()</code></a> method manually.</div>
</div>
<div id="option-cancel" class="api-item">
<h3>cancel<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"input,textarea,button,select,option"</code>
</div>
<div>Prevents selecting if you start on elements matching the selector.</div>
</div>
<div id="option-delay" class="api-item">
<h3>delay<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>Time in milliseconds to define when the selecting should start. This helps prevent unwanted selections when clicking on an element.</div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the selectable if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the selectable with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).selectable({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).selectable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).selectable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-distance" class="api-item">
<h3>distance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>Tolerance, in pixels, for when selecting should start. If specified, selecting will not start until the mouse has been dragged beyond the specified distance.</div>
</div>
<div id="option-filter" class="api-item">
<h3>filter<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"*"</code>
</div>
<div>The matching child elements will be made selectees (able to be selected).</div>
</div>
<div id="option-tolerance" class="api-item">
<h3>tolerance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"touch"</code>
</div>
<div>
Specifies which mode to use for testing whether the lasso should select an item. Possible values:
<ul>
<li>
<code>"fit"</code>: Lasso overlaps the item entirely.</li>
<li>
<code>"touch"</code>: Lasso overlaps the item by any amount.</li>
</ul>
</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the selectable functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the selectable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the selectable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current selectable options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the selectable option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the selectable.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-refresh"><div class="api-item">
<h3>refresh()</h3>
<div>Refresh the position and size of each selectee element. This method can be used to manually recalculate the position and size of each selectee when the <a href="#option-autoRefresh"><code>autoRefresh</code></a> option is set to <code>false</code>.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the selectable element.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-create" class="api-item first-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the selectable is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-selected" class="api-item">
<h3>selected( event, ui )</h3>
<div>Triggered at the end of the select operation, on each element added to the selection.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>selected</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Element">Element</a>
</div>
<div>The selectable item that has been selected.</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-selecting" class="api-item">
<h3>selecting( event, ui )</h3>
<div>Triggered during the select operation, on each element added to the selection.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>selecting</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Element">Element</a>
</div>
<div>The current selectable item being selected.</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-start" class="api-item">
<h3>start( event, ui )</h3>
<div>Triggered at the beginning of the select operation.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-stop" class="api-item">
<h3>stop( event, ui )</h3>
<div>Triggered at the end of the select operation.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-unselected" class="api-item">
<h3>unselected( event, ui )</h3>
<div>Triggered at the end of the select operation, on each element removed from the selection.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>unselected</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Element">Element</a>
</div>
<div>The selectable item that has been unselected.</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-unselecting" class="api-item">
<h3>unselecting( event, ui )</h3>
<div>Triggered during the select operation, on each element removed from the selection.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>unselecting</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Element">Element</a>
</div>
<div>The current selectable item being unselected.</div>
</li></ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>The jQuery UI Selectable plugin allows for elements to be selected by dragging a box (sometimes called a lasso) with the mouse over the elements. Elements can also be selected via click or drag while holding the ctrl/meta key, allowing for multiple (non-contiguous) selections.</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Selectable.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div><div class="line number30 index29 alt1">30</div><div class="line number31 index30 alt2">31</div><div class="line number32 index31 alt1">32</div><div class="line number33 index32 alt2">33</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>selectable demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#selectable .ui-selecting {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">#selectable .ui-selected {</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">background: #999;</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number18 index17 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number19 index18 alt2"> </div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">ul</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"selectable"</code><code class="plain">></code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 1</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 2</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 3</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 4</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number25 index24 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 5</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain">$( "#selectable" ).selectable();</code></div><div class="line number30 index29 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number31 index30 alt2"> </div><div class="line number32 index31 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number33 index32 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="150"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/selectable.html | HTML | bsd | 23,214 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI draggable documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Draggable Widget",
"excerpt":
"Allow elements to be moved using the mouse.",
"termSlugs": {
"category": [
"interactions"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-addClasses">addClasses</a></div>
<div><a href="#option-appendTo">appendTo</a></div>
<div><a href="#option-axis">axis</a></div>
<div><a href="#option-cancel">cancel</a></div>
<div><a href="#option-connectToSortable">connectToSortable</a></div>
<div><a href="#option-containment">containment</a></div>
<div><a href="#option-cursor">cursor</a></div>
<div><a href="#option-cursorAt">cursorAt</a></div>
<div><a href="#option-delay">delay</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-distance">distance</a></div>
<div><a href="#option-grid">grid</a></div>
<div><a href="#option-handle">handle</a></div>
<div><a href="#option-helper">helper</a></div>
<div><a href="#option-iframeFix">iframeFix</a></div>
<div><a href="#option-opacity">opacity</a></div>
<div><a href="#option-refreshPositions">refreshPositions</a></div>
<div><a href="#option-revert">revert</a></div>
<div><a href="#option-revertDuration">revertDuration</a></div>
<div><a href="#option-scope">scope</a></div>
<div><a href="#option-scroll">scroll</a></div>
<div><a href="#option-scrollSensitivity">scrollSensitivity</a></div>
<div><a href="#option-scrollSpeed">scrollSpeed</a></div>
<div><a href="#option-snap">snap</a></div>
<div><a href="#option-snapMode">snapMode</a></div>
<div><a href="#option-snapTolerance">snapTolerance</a></div>
<div><a href="#option-stack">stack</a></div>
<div><a href="#option-zIndex">zIndex</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
<div><a href="#event-start">start</a></div>
<div><a href="#event-drag">drag</a></div>
<div><a href="#event-stop">stop</a></div>
</div></section><article id="draggable1" class="entry widget"><h2 class="section-title">
<span>Draggable Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Allow elements to be moved using the mouse.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-addClasses" class="api-item first-item">
<h3>addClasses<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>If set to <code>false</code>, will prevent the <code>ui-draggable</code> class from being added. This may be desired as a performance optimization when calling <code>.draggable()</code> on hundreds of elements.</div>
</div>
<div id="option-appendTo" class="api-item">
<h3>appendTo<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#jQuery">jQuery</a> or <a href="http://api.jquery.com/Types#Element">Element</a> or <a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"parent"</code>
</div>
<div>Which element the draggable helper should be appended to while dragging.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>jQuery</strong>: A jQuery object containing the element to append the helper to.</li>
<li>
<strong>Element</strong>: The element to append the helper to.</li>
<li>
<strong>Selector</strong>: A selector specifying which element to append the helper to.</li>
<li>
<strong>String</strong>: The string <code>"parent"</code> will cause the helper to be a sibling of the draggable.</li>
</ul>
</div>
<div id="option-axis" class="api-item">
<h3>axis<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Constrains dragging to either the horizontal (x) or vertical (y) axis. Possible values: <code>"x"</code>, <code>"y"</code>.</div>
</div>
<div id="option-cancel" class="api-item">
<h3>cancel<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"input,textarea,button,select,option"</code>
</div>
<div>Prevents dragging from starting on specified elements.</div>
</div>
<div id="option-connectToSortable" class="api-item">
<h3>connectToSortable<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Allows the draggable to be dropped onto the specified sortables. If this option is used, a draggable can be dropped onto a sortable list and then becomes part of it. Note: The <a href="#option-helper"><code>helper</code></a> option must be set to <code>"clone"</code> in order to work flawlessly. Requires the <a href="/sortable/">jQuery UI Sortable plugin</a> to be included.</div>
</div>
<div id="option-containment" class="api-item">
<h3>containment<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#Element">Element</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Constrains dragging to within the bounds of the specified element or region.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Selector</strong>: The draggable element will be contained to the bounding box of the first element found by the selector. If no element is found, no containment will be set.</li>
<li>
<strong>Element</strong>: The draggable element will be contained to the bounding box of this element.</li>
<li>
<strong>String</strong>: Possible values: <code>"parent"</code>, <code>"document"</code>, <code>"window"</code>.</li>
<li>
<strong>Array</strong>: An array defining a bounding box in the form <code>[ x1, y1, x2, y2 ]</code>.</li>
</ul>
</div>
<div id="option-cursor" class="api-item">
<h3>cursor<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"auto"</code>
</div>
<div>The CSS cursor during the drag operation.</div>
</div>
<div id="option-cursorAt" class="api-item">
<h3>cursorAt<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Sets the offset of the dragging helper relative to the mouse cursor. Coordinates can be given as a hash using a combination of one or two keys: <code>{ top, left, right, bottom }</code>.</div>
</div>
<div id="option-delay" class="api-item">
<h3>delay<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>Time in milliseconds after mousedown until dragging should start. This option can be used to prevent unwanted drags when clicking on an element.</div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the draggable if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the draggable with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).draggable({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).draggable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).draggable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-distance" class="api-item">
<h3>distance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1</code>
</div>
<div>Distance in pixels after mousedown the mouse must move before dragging should start. This option can be used to prevent unwanted drags when clicking on an element.</div>
</div>
<div id="option-grid" class="api-item">
<h3>grid<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Snaps the dragging helper to a grid, every x and y pixels. The array must be of the form <code>[ x, y ]</code>.</div>
</div>
<div id="option-handle" class="api-item">
<h3>handle<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#Element">Element</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If specified, restricts dragging from starting unless the mousedown occurs on the specified element(s).</div>
</div>
<div id="option-helper" class="api-item">
<h3>helper<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types/#Function">Function</a>()</span>
</h3>
<div class="default">
<strong>Default: </strong><code>"original"</code>
</div>
<div>Allows for a helper element to be used for dragging display.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>String</strong>: If set to <code>"clone"</code>, then the element will be cloned and the clone will be dragged.</li>
<li>
<strong>Function</strong>: A function that will return a DOMElement to use while dragging.</li>
</ul>
</div>
<div id="option-iframeFix" class="api-item">
<h3>iframeFix<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Prevent iframes from capturing the mousemove events during a drag. Useful in combination with the <a href="#option-cursorAt"><code>cursorAt</code></a> option, or in any case where the mouse cursor may not be over the helper.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: When set to <code>true</code>, transparent overlays will be placed over all iframes on the page.</li>
<li>
<strong>Selector</strong>: Any iframes matching the selector will be covered by transparent overlays.</li>
</ul>
</div>
<div id="option-opacity" class="api-item">
<h3>opacity<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Opacity for the helper while being dragged.</div>
</div>
<div id="option-refreshPositions" class="api-item">
<h3>refreshPositions<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>
If set to <code>true</code>, all droppable positions are calculated on every mousemove.
<em>Caution: This solves issues on highly dynamic pages, but dramatically decreases performance.</em>
</div>
</div>
<div id="option-revert" class="api-item">
<h3>revert<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the element should revert to its start position when dragging stops.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: If set to <code>true</code> the element will always revert.</li>
<li>
<strong>String</strong>: If set to <code>"invalid"</code>, revert will only occur if the draggable has not been dropped on a droppable. For <code>"valid"</code>, it's the other way around.</li>
</ul>
</div>
<div id="option-revertDuration" class="api-item">
<h3>revertDuration<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>500</code>
</div>
<div>The duration of the revert animation, in milliseconds. Ignored if the <a href="#option-revert"><code>revert</code></a> option is <code>false</code>.</div>
</div>
<div id="option-scope" class="api-item">
<h3>scope<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"default"</code>
</div>
<div>Used to group sets of draggable and droppable items, in addition to droppable's <a href="/droppable#option-accept"><code>accept</code></a> option. A draggable with the same <code>scope</code> value as a droppable will be accepted by the droppable.</div>
</div>
<div id="option-scroll" class="api-item">
<h3>scroll<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>If set to <code>true</code>, container auto-scrolls while dragging.</div>
</div>
<div id="option-scrollSensitivity" class="api-item">
<h3>scrollSensitivity<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>20</code>
</div>
<div>Distance in pixels from the edge of the viewport after which the viewport should scroll. Distance is relative to pointer, not the draggable. Ignored if the <a href="#option-scroll"><code>scroll</code></a> option is <code>false</code>.</div>
</div>
<div id="option-scrollSpeed" class="api-item">
<h3>scrollSpeed<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>20</code>
</div>
<div>The speed at which the window should scroll once the mouse pointer gets within the <a href="#option-scrollSensitivity"><code>scrollSensitivity</code></a> distance. Ignored if the <a href="#option-scroll"><code>scroll</code></a> option is <code>false</code>.</div>
</div>
<div id="option-snap" class="api-item">
<h3>snap<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the element should snap to other elements.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: When set to <code>true</code>, the element will snap to all other draggable elements.</li>
<li>
<strong>Selector</strong>: A selector specifying which elements to snap to.</li>
</ul>
</div>
<div id="option-snapMode" class="api-item">
<h3>snapMode<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"both"</code>
</div>
<div>Determines which edges of snap elements the draggable will snap to. Ignored if the <a href="#option-snap"><code>snap</code></a> option is <code>false</code>. Possible values: <code>"inner"</code>, <code>"outer"</code>, <code>"both"</code>.</div>
</div>
<div id="option-snapTolerance" class="api-item">
<h3>snapTolerance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>20</code>
</div>
<div>The distance in pixels from the snap element edges at which snapping should occur. Ignored if the <a href="#option-snap"><code>snap</code></a> option is <code>false</code>.</div>
</div>
<div id="option-stack" class="api-item">
<h3>stack<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Controls the z-index of the set of elements that match the selector, always brings the currently dragged item to the front. Very useful in things like window managers.</div>
</div>
<div id="option-zIndex" class="api-item">
<h3>zIndex<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Z-index for the helper while being dragged.</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the draggable functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the draggable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the draggable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current draggable options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the draggable option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the draggable.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the draggable element.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-create" class="api-item first-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the draggable is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-drag" class="api-item">
<h3>drag( event, ui )</h3>
<div>Triggered while the mouse is moved during the dragging.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper that's being dragged.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current CSS position of the helper as <code>{ top, left }</code> object.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current offset position of the helper as <code>{ top, left }</code> object.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-start" class="api-item">
<h3>start( event, ui )</h3>
<div>Triggered when dragging starts.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper that's being dragged.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current CSS position of the helper as <code>{ top, left }</code> object.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current offset position of the helper as <code>{ top, left }</code> object.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-stop" class="api-item">
<h3>stop( event, ui )</h3>
<div>Triggered when dragging stops.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper that's being dragged.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current CSS position of the helper as <code>{ top, left }</code> object.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current offset position of the helper as <code>{ top, left }</code> object.</div>
</li>
</ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>Make the selected elements draggable by mouse. If you want not just drag, but drag & drop, see the <a href="/droppable/">jQuery UI Droppable plugin</a>, which provides a drop target for draggables.</p>
</div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Draggable</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>draggable demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#draggable {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"draggable"</code><code class="plain">>Drag me</</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number20 index19 alt1"> </div><div class="line number21 index20 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number22 index21 alt1"><code class="plain">$( "#draggable" ).draggable();</code></div><div class="line number23 index22 alt2"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number24 index23 alt1"> </div><div class="line number25 index24 alt2"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/draggable.html | HTML | bsd | 32,515 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI button documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Button Widget",
"excerpt":
"Themable buttons and button sets.",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-icons">icons</a></div>
<div><a href="#option-label">label</a></div>
<div><a href="#option-text">text</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-refresh">refresh</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
</div></section><article id="button1" class="entry widget"><h2 class="section-title">
<span>Button Widget</span><span class="version-details">version added: 1.8</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Themable buttons and button sets.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-disabled" class="api-item first-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the button if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the button with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).button({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).button( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).button( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-icons" class="api-item">
<h3>icons<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{ primary: null, secondary: null }</code>
</div>
<div>Icons to display, with or without text (see <a href="#option-text"><code>text</code></a> option). By default, the primary icon is displayed on the left of the label text and the secondary is displayed on the right. The positioning can be controlled via CSS. The value for the <code>primary</code> and <code>secondary</code> properties must be a class name, e.g., <code>"ui-icon-gear"</code>. For using only one icon: <code>icons: { primary: "ui-icon-locked" }</code>. For using two icons: <code>icons: { primary: "ui-icon-gear", secondary: "ui-icon-triangle-1-s" }</code>.</div>
<strong>Code examples:</strong><p>Initialize the button with the icons option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).button({ icons: { primary: </code><code class="string">"ui-icon-gear"</code><code class="plain">, secondary: </code><code class="string">"ui-icon-triangle-1-s"</code> <code class="plain">} });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the icons option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">icons = $( </code><code class="string">".selector"</code> <code class="plain">).button( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"icons"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).button( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"icons"</code><code class="plain">, { primary: </code><code class="string">"ui-icon-gear"</code><code class="plain">, secondary: </code><code class="string">"ui-icon-triangle-1-s"</code> <code class="plain">} );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-label" class="api-item">
<h3>label<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>Text to show in the button. When not specified (<code>null</code>), the element's HTML content is used, or its <code>value</code> attribute if the element is an input element of type submit or reset, or the HTML content of the associated label element if the element is an input of type radio or checkbox.</div>
<strong>Code examples:</strong><p>Initialize the button with the label option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).button({ label: </code><code class="string">"custom label"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the label option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">label = $( </code><code class="string">".selector"</code> <code class="plain">).button( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"label"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).button( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"label"</code><code class="plain">, </code><code class="string">"custom label"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-text" class="api-item">
<h3>text<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>Whether to show the label. When set to <code>false</code> no text will be displayed, but the <a href="#options-icons"><code>icons</code></a> option must be enabled, otherwise the <code>text</code> option will be ignored.</div>
<strong>Code examples:</strong><p>Initialize the button with the text option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).button({ text: </code><code class="keyword">false</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the text option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">text = $( </code><code class="string">".selector"</code> <code class="plain">).button( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"text"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).button( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"text"</code><code class="plain">, </code><code class="keyword">false</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the button functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the button.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the button.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current button options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the button option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the button.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-refresh"><div class="api-item">
<h3>refresh()</h3>
<div>Refreshes the visual state of the button. Useful for updating button state after the native element's checked or disabled state is changed programmatically.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the element visually representing the button.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-create" class="api-item first-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the button is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>Button enhances standard form elements like buttons, inputs and anchors to themable buttons with appropiate hover and active styles.</p>
<p>In addition to basic push buttons, radio buttons and checkboxes (inputs of type radio and checkbox) can be converted to buttons. Their associated label is styled to appear as the button, while the underlying input is updated on click. For the association to work properly, give the input an <code>id</code> attribute, and refer to that in the label's <code>for</code> attribute. Don't nest the input inside the label, as that <a href="http://www.paciellogroup.com/blog/2011/07/html5-accessibility-chops-form-control-labeling/">causes accessbility problems</a>.</p>
<p>In order to group radio buttons, Button also provides an additional widget, called Buttonset. Buttonset is used by selecting a container element (which contains the radio buttons) and calling <code>.buttonset()</code>. Buttonset will also provide visual grouping, and therefore should be used whenever you have a group of buttons. It works by selecting all descendants and applying <code>.button()</code> to them. You can enable and disable a button set, which will enable and disable all contained buttons. Destroying a button set also calls each button's <code>destroy</code> method.</p>
<p>When using an input of type button, submit or reset, support is limited to plain text labels with no icons.</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Examples:</h2></header><div class="entry-example" id="example-0">
<h4>Example: <span class="desc">A simple jQuery UI Button</span>
</h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>button demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">button</code><code class="plain">>Button label</</code><code class="keyword">button</code><code class="plain">></code></div><div class="line number13 index12 alt2"> </div><div class="line number14 index13 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="plain">$( "button" ).button();</code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number17 index16 alt2"> </div><div class="line number18 index17 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number19 index18 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="100"></div>
</div>
<div class="entry-example" id="example-1">
<h4>Example: <span class="desc">A simple jQuery UI Buttonset</span>
</h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>button demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"radio"</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">input</code> <code class="color1">type</code><code class="plain">=</code><code class="string">"radio"</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"radio1"</code> <code class="color1">name</code><code class="plain">=</code><code class="string">"radio"</code><code class="plain">><</code><code class="keyword">label</code> <code class="color1">for</code><code class="plain">=</code><code class="string">"radio1"</code><code class="plain">>Choice 1</</code><code class="keyword">label</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">input</code> <code class="color1">type</code><code class="plain">=</code><code class="string">"radio"</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"radio2"</code> <code class="color1">name</code><code class="plain">=</code><code class="string">"radio"</code> <code class="color1">checked</code><code class="plain">=</code><code class="string">"checked"</code><code class="plain">><</code><code class="keyword">label</code> <code class="color1">for</code><code class="plain">=</code><code class="string">"radio2"</code><code class="plain">>Choice 2</</code><code class="keyword">label</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">input</code> <code class="color1">type</code><code class="plain">=</code><code class="string">"radio"</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"radio3"</code> <code class="color1">name</code><code class="plain">=</code><code class="string">"radio"</code><code class="plain">><</code><code class="keyword">label</code> <code class="color1">for</code><code class="plain">=</code><code class="string">"radio3"</code><code class="plain">>Choice 3</</code><code class="keyword">label</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number17 index16 alt2"> </div><div class="line number18 index17 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number19 index18 alt2"><code class="plain">$( "#radio" ).buttonset();</code></div><div class="line number20 index19 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="100"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/button.html | HTML | bsd | 28,923 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI progressbar documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Progressbar Widget",
"excerpt":
"Display status of a determinate process.",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-value">value</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-value">value</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-change">change</a></div>
<div><a href="#event-create">create</a></div>
<div><a href="#event-complete">complete</a></div>
</div></section><article id="progressbar1" class="entry widget"><h2 class="section-title">
<span>Progressbar Widget</span><span class="version-details">version added: 1.6</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Display status of a determinate process.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-disabled" class="api-item first-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the progressbar if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the progressbar with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).progressbar({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).progressbar( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).progressbar( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-value" class="api-item">
<h3>value<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>The value of the progressbar.</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the progressbar functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the progressbar.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the progressbar.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current progressbar options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the progressbar option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the progressbar.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-value">
<div class="api-item">
<h3>value() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Number">Number</a></span>
</h3>
<div>Gets the current value of the progressbar.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>value( value )</h3>
<div>Sets the current value of the progressbar.</div>
<ul><li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The value to set.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the progressbar.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-change" class="api-item first-item">
<h3>change( event, ui )</h3>
<div>Triggered when the value of the progressbar changes.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-complete" class="api-item">
<h3>complete( event, ui )</h3>
<div>Triggered when the value of the progressbar reaches the maximum value.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the progressbar is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>
The progress bar is designed to display the current percent complete for a process. The bar is coded to be flexibly sized through CSS and will scale to fit inside its parent container by default.
</p>
<p>
This is a determinate progress bar, meaning that it should only be used in situations where the system can accurately update the current status. A determinate progress bar should never fill from left to right, then loop back to empty for a single process — if the actual status cannot be calculated, an indeterminate progress bar or spinner animation is a better way to provide user feedback.
</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Progressbar</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>progressbar demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"progressbar"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number13 index12 alt2"> </div><div class="line number14 index13 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="plain">$( "#progressbar" ).progressbar({</code></div><div class="line number16 index15 alt1"><code class="undefined spaces"> </code><code class="plain">value: 37</code></div><div class="line number17 index16 alt2"><code class="plain">});</code></div><div class="line number18 index17 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number19 index18 alt2"> </div><div class="line number20 index19 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number21 index20 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="50"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/progressbar.html | HTML | bsd | 15,240 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI shake-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Shake Effect",
"excerpt":
"Shakes the element multiple times, vertically or horizontally.",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="shake1" class="entry effect"><h2 class="section-title"><span>Shake Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Shakes the element multiple times, vertically or horizontally.</p>
<ul class="signatures"><li class="signature">
<h4 class="name">shake</h4>
<ul>
<li>
<div>
<strong>direction</strong> (default: <code>"both"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The direction of the effect. Possible values: <code>"left"</code>, <code>"right"</code>, <code>"up"</code>, <code>"down"</code>.</div>
</li>
<li>
<div>
<strong>distance</strong> (default: <code>20</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>Distance to shake.</div>
</li>
<li>
<div>
<strong>times</strong> (default: <code>3</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Integer">Integer</a>
</div>
<div>Times to shake.</div>
</li>
</ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Shake a div.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>shake demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to shake the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).effect( "shake" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/shake-effect.html | HTML | bsd | 8,916 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI transfer-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Transfer Effect",
"excerpt":
"Transfers the outline of an element to another element",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="transfer1" class="entry effect"><h2 class="section-title"><span>Transfer Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Transfers the outline of an element to another element</p>
<ul class="signatures"><li class="signature">
<h4 class="name">transfer</h4>
<ul>
<li>
<div><strong>className</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>argumental class name the transfer element will receive.</div>
</li>
<li>
<div><strong>to</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>jQuery selector, the element to transfer to.</div>
</li>
</ul>
</li></ul>
<div class="longdesc" id="entry-longdesc">
<p>Very useful when trying to visualize interaction between two elements.</p>
<p>The transfer element iself has the class <code>ui-effects-transfer</code>, and needs to be styled by you, for example by adding a background or border.</p>
</div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Clicking on the green element transfers to the other.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div><div class="line number30 index29 alt1">30</div><div class="line number31 index30 alt2">31</div><div class="line number32 index31 alt1">32</div><div class="line number33 index32 alt2">33</div><div class="line number34 index33 alt1">34</div><div class="line number35 index34 alt2">35</div><div class="line number36 index35 alt1">36</div><div class="line number37 index36 alt2">37</div><div class="line number38 index37 alt1">38</div><div class="line number39 index38 alt2">39</div><div class="line number40 index39 alt1">40</div><div class="line number41 index40 alt2">41</div><div class="line number42 index41 alt1">42</div><div class="line number43 index42 alt2">43</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>transfer demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">div.green {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 80px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: green;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">border: 1px solid black;</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain">position: relative;</code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain">div.red {</code></div><div class="line number16 index15 alt1"><code class="undefined spaces"> </code><code class="plain">margin-top: 10px;</code></div><div class="line number17 index16 alt2"><code class="undefined spaces"> </code><code class="plain">width: 50px;</code></div><div class="line number18 index17 alt1"><code class="undefined spaces"> </code><code class="plain">height: 30px;</code></div><div class="line number19 index18 alt2"><code class="undefined spaces"> </code><code class="plain">background: red;</code></div><div class="line number20 index19 alt1"><code class="undefined spaces"> </code><code class="plain">border: 1px solid black;</code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain">position: relative;</code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number23 index22 alt2"><code class="undefined spaces"> </code><code class="plain">.ui-effects-transfer {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">border: 1px dotted black;</code></div><div class="line number25 index24 alt2"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number26 index25 alt1"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number27 index26 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number28 index27 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number30 index29 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number31 index30 alt2"> </div><div class="line number32 index31 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">class</code><code class="plain">=</code><code class="string">"green"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number33 index32 alt2"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">class</code><code class="plain">=</code><code class="string">"red"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number34 index33 alt1"> </div><div class="line number35 index34 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number36 index35 alt1"><code class="plain">$( "div" ).click(function() {</code></div><div class="line number37 index36 alt2"><code class="undefined spaces"> </code><code class="plain">var i = 1 - $( "div" ).index( this );</code></div><div class="line number38 index37 alt1"><code class="undefined spaces"> </code><code class="plain">$( this ).effect( "transfer", { to: $( "div" ).eq( i ) }, 1000 );</code></div><div class="line number39 index38 alt2"><code class="plain">});</code></div><div class="line number40 index39 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number41 index40 alt2"> </div><div class="line number42 index41 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number43 index42 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="150"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/transfer-effect.html | HTML | bsd | 12,081 |
<script>{
"title":
"Size Effect",
"excerpt":
"Resize an element to a specified width and height.",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="size1" class="entry effect"><h2 class="section-title"><span>Size Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Resize an element to a specified width and height.</p>
<ul class="signatures"><li class="signature">
<h4 class="name">size</h4>
<ul>
<li>
<div><strong>to</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Height and width to resize to.</div>
</li>
<li>
<div>
<strong>origin</strong> (default: <code>[ "top", "left" ]</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Array">Array</a>
</div>
<div>The vanishing point.</div>
</li>
<li>
<div>
<strong>scale</strong> (default: <code>"both"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>Which areas of the element will be resized: <code>"both"</code>, <code>"box"</code>, <code>"content"</code>. Box resizes the border and padding of the element; content resizes any content inside of the element.</div>
</li>
</ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Resize the element using the size effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div><div class="line number30 index29 alt1">30</div><div class="line number31 index30 alt2">31</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>size demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to resize the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).effect( "size", {</code></div><div class="line number25 index24 alt2"><code class="undefined spaces"> </code><code class="plain">to: { width: 200, height: 60 }</code></div><div class="line number26 index25 alt1"><code class="undefined spaces"> </code><code class="plain">}, 1000 );</code></div><div class="line number27 index26 alt2"><code class="plain">});</code></div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number29 index28 alt2"> </div><div class="line number30 index29 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number31 index30 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article> | 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/size-effect.html | HTML | bsd | 9,130 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI highlight-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Highlight Effect",
"excerpt":
"\n\t\tThe highlight effect hides or shows an element by animating its background color first.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="highlight1" class="entry effect"><h2 class="section-title"><span>Highlight Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The highlight effect hides or shows an element by animating its background color first.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">highlight</h4>
<ul><li>
<div>
<strong>color</strong> (default: <code>"#ffff99"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The background color used during the animation.</div>
</li></ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the highlight effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>highlight demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "highlight" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/highlight-effect.html | HTML | bsd | 8,599 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI droppable documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Droppable Widget",
"excerpt":
"Create targets for draggable elements.",
"termSlugs": {
"category": [
"interactions"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-accept">accept</a></div>
<div><a href="#option-activeClass">activeClass</a></div>
<div><a href="#option-addClasses">addClasses</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-greedy">greedy</a></div>
<div><a href="#option-hoverClass">hoverClass</a></div>
<div><a href="#option-scope">scope</a></div>
<div><a href="#option-tolerance">tolerance</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
<div><a href="#event-activate">activate</a></div>
<div><a href="#event-deactivate">deactivate</a></div>
<div><a href="#event-over">over</a></div>
<div><a href="#event-out">out</a></div>
<div><a href="#event-drop">drop</a></div>
</div></section><article id="droppable1" class="entry widget"><h2 class="section-title">
<span>Droppable Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Create targets for draggable elements.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-accept" class="api-item first-item">
<h3>accept<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types/#Function">Function</a>()</span>
</h3>
<div class="default">
<strong>Default: </strong><code>"*"</code>
</div>
<div>Controls which draggable elements are accepted by the droppable.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Selector</strong>: A selector indicating which draggable elements are accepted.</li>
<li>
<strong>Function</strong>: A function that will be called for each draggable on the page (passed as the first argument to the function). The function must return <code>true</code> if the draggable should be accepted.</li>
</ul>
</div>
<div id="option-activeClass" class="api-item">
<h3>activeClass<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If specified, the class will be added to the droppable while an acceptable draggable is being dragged.</div>
</div>
<div id="option-addClasses" class="api-item">
<h3>addClasses<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>If set to <code>false</code>, will prevent the <code>ui-droppable</code> class from being added. This may be desired as a performance optimization when calling <code>.droppable()</code> init on hundreds of elements.</div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the droppable if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the droppable with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).droppable({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).droppable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).droppable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-greedy" class="api-item">
<h3>greedy<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>By default, when an element is dropped on nested droppables, each droppable will receive the element. However, by setting this option to <code>true</code>, any parent droppables will not receive the element.</div>
</div>
<div id="option-hoverClass" class="api-item">
<h3>hoverClass<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If specified, the class will be added to the droppable while an acceptable draggable is being hovered over the droppable.</div>
</div>
<div id="option-scope" class="api-item">
<h3>scope<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"default"</code>
</div>
<div>Used to group sets of draggable and droppable items, in addition to the <a href="#option-accept"><code>accept</code></a> option. A draggable with the same scope value as a droppable will be accepted.</div>
</div>
<div id="option-tolerance" class="api-item">
<h3>tolerance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"intersect"</code>
</div>
<div>
Specifies which mode to use for testing whether a draggable is hovering over a droppable. Possible values:
<ul>
<li>
<code>"fit"</code>: Draggable overlaps the droppable entirely.</li>
<li>
<code>"intersect"</code>: Draggable overlaps the droppable at least 50% in both directions.</li>
<li>
<code>"pointer"</code>: Mouse pointer overlaps the droppable.</li>
<li>
<code>"touch"</code>: Draggable overlaps the droppable any amount.</li>
</ul>
</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the droppable functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the droppable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the droppable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current droppable options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the droppable option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the droppable.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the droppable element.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-activate" class="api-item first-item">
<h3>activate( event, ui )</h3>
<div>Triggered when an accepted draggable starts dragging. This can be useful if you want to make the droppable "light up" when it can be dropped on.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>draggable</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>A jQuery object representing the draggable element.</div>
</li>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>A jQuery object representing the helper that is being dragged.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current CSS position of the draggable helper as <code>{ top, left }</code> object.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current offset position of the draggable helper as <code>{ top, left }</code> object.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the droppable is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-deactivate" class="api-item">
<h3>deactivate( event, ui )</h3>
<div>Triggered when an accepted draggable stops dragging.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>draggable</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>A jQuery object representing the draggable element.</div>
</li>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>A jQuery object representing the helper that is being dragged.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current CSS position of the draggable helper as <code>{ top, left }</code> object.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current offset position of the draggable helper as <code>{ top, left }</code> object.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-drop" class="api-item">
<h3>drop( event, ui )</h3>
<div>Triggered when an accepted draggable is dropped on the droppable (based on the<a href="#option-tolerance"><code>tolerance</code></a> option).</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>draggable</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>A jQuery object representing the draggable element.</div>
</li>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>A jQuery object representing the helper that is being dragged.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current CSS position of the draggable helper as <code>{ top, left }</code> object.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current offset position of the draggable helper as <code>{ top, left }</code> object.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-out" class="api-item">
<h3>out( event, ui )</h3>
<div>Triggered when an accepted draggable is dragged out of the droppable (based on the<a href="#option-tolerance"><code>tolerance</code></a> option).</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-over" class="api-item">
<h3>over( event, ui )</h3>
<div>Triggered when an accepted draggable is dragged over the droppable (based on the<a href="#option-tolerance"><code>tolerance</code></a> option).</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>draggable</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>A jQuery object representing the draggable element.</div>
</li>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>A jQuery object representing the helper that is being dragged.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current CSS position of the draggable helper as <code>{ top, left }</code> object.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Current offset position of the draggable helper as <code>{ top, left }</code> object.</div>
</li>
</ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>The jQuery UI Droppable plugin makes selected elements droppable (meaning they accept being dropped on by <a href="/draggable/">draggables</a>). You can specify which draggables each will accept.</p>
</div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A pair of draggable and droppable elements.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div><div class="line number30 index29 alt1">30</div><div class="line number31 index30 alt2">31</div><div class="line number32 index31 alt1">32</div><div class="line number33 index32 alt2">33</div><div class="line number34 index33 alt1">34</div><div class="line number35 index34 alt2">35</div><div class="line number36 index35 alt1">36</div><div class="line number37 index36 alt2">37</div><div class="line number38 index37 alt1">38</div><div class="line number39 index38 alt2">39</div><div class="line number40 index39 alt1">40</div><div class="line number41 index40 alt2">41</div><div class="line number42 index41 alt1">42</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>droppable demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#draggable {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain">#droppable {</code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain">position: absolute;</code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain">left: 250px;</code></div><div class="line number16 index15 alt1"><code class="undefined spaces"> </code><code class="plain">top: 0;</code></div><div class="line number17 index16 alt2"><code class="undefined spaces"> </code><code class="plain">width: 125px;</code></div><div class="line number18 index17 alt1"><code class="undefined spaces"> </code><code class="plain">height: 125px;</code></div><div class="line number19 index18 alt2"><code class="undefined spaces"> </code><code class="plain">background: #999;</code></div><div class="line number20 index19 alt1"><code class="undefined spaces"> </code><code class="plain">color: #fff;</code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain">padding: 10px;</code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number23 index22 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number25 index24 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number27 index26 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number28 index27 alt1"> </div><div class="line number29 index28 alt2"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"droppable"</code><code class="plain">>Drop here</</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number30 index29 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"draggable"</code><code class="plain">>Drag me</</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number31 index30 alt2"> </div><div class="line number32 index31 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number33 index32 alt2"><code class="plain">$( "#draggable" ).draggable();</code></div><div class="line number34 index33 alt1"><code class="plain">$( "#droppable" ).droppable({</code></div><div class="line number35 index34 alt2"><code class="undefined spaces"> </code><code class="plain">drop: function() {</code></div><div class="line number36 index35 alt1"><code class="undefined spaces"> </code><code class="plain">alert( "dropped" );</code></div><div class="line number37 index36 alt2"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number38 index37 alt1"><code class="plain">});</code></div><div class="line number39 index38 alt2"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number40 index39 alt1"> </div><div class="line number41 index40 alt2"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number42 index41 alt1"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/droppable.html | HTML | bsd | 27,277 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI mouse documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Mouse Interaction",
"excerpt":
"The base interaction layer.",
"termSlugs": {
"category": [
"utilities","interactions"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-cancel">cancel</a></div>
<div><a href="#option-delay">delay</a></div>
<div><a href="#option-distance">distance</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-_mouseInit">_mouseInit</a></div>
<div><a href="#method-_mouseDestroy">_mouseDestroy</a></div>
<div><a href="#method-_mouseDown">_mouseDown</a></div>
<div><a href="#method-_mouseMove">_mouseMove</a></div>
<div><a href="#method-_mouseUp">_mouseUp</a></div>
<div><a href="#method-_mouseDistanceMet">_mouseDistanceMet</a></div>
<div><a href="#method-_mouseDelayMet">_mouseDelayMet</a></div>
<div><a href="#method-_mouseStart">_mouseStart</a></div>
<div><a href="#method-_mouseDrag">_mouseDrag</a></div>
<div><a href="#method-_mouseStop">_mouseStop</a></div>
<div><a href="#method-_mouseCapture">_mouseCapture</a></div>
</div>
<div class="quick-nav-section"><h3>Events</h3></div></section><article id="jQuery-ui-mouse1" class="entry widget"><h2 class="section-title"><span>Mouse Interaction</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>The base interaction layer.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-cancel" class="api-item first-item">
<h3>cancel<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"input,textarea,button,select,option"</code>
</div>
<div>Prevents interactions from starting on specified elements.</div>
</div>
<div id="option-delay" class="api-item">
<h3>delay<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>Time in milliseconds after mousedown until the interaction should start. This option can be used to prevent unwanted interactions when clicking on an element.</div>
</div>
<div id="option-distance" class="api-item">
<h3>distance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1</code>
</div>
<div>Distance in pixels after mousedown the mouse must move before the interaction should start. This option can be used to prevent unwanted interactions when clicking on an element.</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-_mouseCapture"><div class="api-item first-item">
<h3>_mouseCapture() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Boolean">Boolean</a></span>
</h3>
<div>
Determines whether an interaction should start based on event target of the interaction. The default implementation always returns <code>true</code>.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseDelayMet"><div class="api-item">
<h3>_mouseDelayMet() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Boolean">Boolean</a></span>
</h3>
<div>
Determines whether the <a href="#option-delay"><code>delay</code></a> option has been met for the current interaction.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseDestroy"><div class="api-item">
<h3>_mouseDestroy()</h3>
<div>
Destroys the interaction event handlers. This must be called from the extending widget's <code>_destroy()</code> method.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseDistanceMet"><div class="api-item">
<h3>_mouseDistanceMet() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Boolean">Boolean</a></span>
</h3>
<div>
Determines whether the <a href="#option-distance"><code>distance</code></a> option has been met for the current interaction.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseDown"><div class="api-item">
<h3>_mouseDown()</h3>
<div>
Handles the beginning of an interaction. Verifies that the event is associated with the primary mouse button and ensures that the <a href="#option-delay"><code>delay</code></a> and <a href="#option-distance"><code>distance</code></a> options are met prior to starting the interaction. When the interaction is ready to start, invokes the <a href="#method-_mouseStart"><code>_mouseStart()</code></a> method for the extending widget to handle.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseDrag"><div class="api-item">
<h3>_mouseDrag()</h3>
<div>
The extending widget should implement a <code>_mouseDrag()</code> method to handle each movement of an interaction. This method will receive the mouse event associated with the movement.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseInit"><div class="api-item">
<h3>_mouseInit()</h3>
<div>
Initializes the interaction event handlers. This must be called from the extending widget's <code>_create()</code> method.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseMove"><div class="api-item">
<h3>_mouseMove()</h3>
<div>
Handles each movement of the interaction. Invokes the <a href="#method-_mouseDrag"><code>mouseDrag()</code></a> method for the extending widget to handle.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseStart"><div class="api-item">
<h3>_mouseStart()</h3>
<div>
The extending widget should implement a <code>_mouseStart()</code> method to handle the beginning of an interaction. This method will receive the mouse event associated with the start of the interaction.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseStop"><div class="api-item">
<h3>_mouseStop()</h3>
<div>
The extending widget should implement a <code>_mouseStop()</code> method to handle the end of an interaction. This method will receive the mouse event associated with the end of the interaction.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_mouseUp"><div class="api-item">
<h3>_mouseUp()</h3>
<div>
Handles the end of the interaction. Invokes the <a href="#method-_mouseStop"><code>mouseStop()</code></a> method for the extending widget to handle.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><div class="longdesc" id="entry-longdesc">
<p>Similar to <a href="/jQuery.Widget#jQuery-Widget2"><code>jQuery.Widget</code></a>, the mouse interaction is not intended to be used directly. It is purely a base layer for other widgets to inherit from. This page only documents what is added to <code>jQuery.Widget</code>, but it does include internal methods that are not intended to be overwritten. The intended public API is <a href="#method-_mouseStart"><code>_mouseStart()</code></a>, <a href="#method-_mouseDrag"><code>_mouseDrag()</code></a>, <a href="#method-_mouseStop"><code>_mouseStop()</code></a>, and <a href="#method-_mouseCapture"><code>_mouseCapture()</code></a>.</p>
</div>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/mouse.html | HTML | bsd | 8,389 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI fold-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Fold Effect",
"excerpt":
"\n\t\tThe fold effect hides or shows an element by folding it.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="fold1" class="entry effect"><h2 class="section-title"><span>Fold Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The fold effect hides or shows an element by folding it.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">fold</h4>
<ul>
<li>
<div>
<strong>size</strong> (default: <code>15</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The size of the "folded" element.</div>
</li>
<li>
<div>
<strong>horizFirst</strong> (default: <code>false</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Boolean">Boolean</a>
</div>
<div>Whether the horizontal direction happens first when hiding. Remember, showing inverts hiding.</div>
</li>
</ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the fold effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>fold demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "fold" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/fold-effect.html | HTML | bsd | 8,798 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI tabs documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Tabs Widget",
"excerpt":
"A single content area with multiple panels, each associated with a header in a list.",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-active">active</a></div>
<div><a href="#option-collapsible">collapsible</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-event">event</a></div>
<div><a href="#option-heightStyle">heightStyle</a></div>
<div><a href="#option-hide">hide</a></div>
<div><a href="#option-show">show</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-load">load</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-refresh">refresh</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-activate">activate</a></div>
<div><a href="#event-beforeActivate">beforeActivate</a></div>
<div><a href="#event-beforeLoad">beforeLoad</a></div>
<div><a href="#event-create">create</a></div>
<div><a href="#event-load">load</a></div>
</div></section><article id="tabs1" class="entry widget"><h2 class="section-title">
<span>Tabs Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>A single content area with multiple panels, each associated with a header in a list.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-active" class="api-item first-item">
<h3>active<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>
Which panel is currently open.
</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: Setting <code>active</code> to <code>false</code> will collapse all panels. This requires the <a href="#option-collapsible"><code>collapsible</code></a> option to be <code>true</code>.</li>
<li>
<strong>Integer</strong>: The zero-based index of the panel that is active (open). A negative value selects panels going backward from the last panel.</li>
</ul>
</div>
<div id="option-collapsible" class="api-item">
<h3>collapsible<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>When set to <code>true</code>, the active panel can be closed.</div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Which tabs are disabled.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: Enable or disable all tabs.</li>
<li>
<strong>Array</strong>: An array containing the zero-based indexes of the tabs that should be disabled, e.g., <code>[ 0, 2 ]</code> would disable the first and third tab.</li>
</ul>
</div>
<div id="option-event" class="api-item">
<h3>event<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"click"</code>
</div>
<div>The type of event that the tabs should react to in order to activate the tab. To activate on hover, use <code>"mouseover"</code>.</div>
</div>
<div id="option-heightStyle" class="api-item">
<h3>heightStyle<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"content"</code>
</div>
<div>
Controls the height of the tabs widget and each panel. Possible values:
<ul>
<li>
<code>"auto"</code>: All panels will be set to the height of the tallest panel.</li>
<li>
<code>"fill"</code>: Expand to the available height based on the tabs' parent height.</li>
<li>
<code>"content"</code>: Each panel will be only as tall as its content.</li>
</ul>
</div>
</div>
<div id="option-hide" class="api-item">
<h3>hide<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>If and how to animate the hiding of the panel.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>:
When set to <code>false</code>, no animation will be used and the panel will be hidden immediately.
When set to <code>true</code>, the panel will fade out with the default duration and the default easing.
</li>
<li>
<strong>Number</strong>:
The panel will fade out with the specified duration and the default easing.
</li>
<li>
<strong>String</strong>:
The panel will be hidden using the specified effect.
The value can either be the name of a built-in jQuery animateion method, such as <code>"slideUp"</code>, or the name of a jQuery UI effect, such as <code>"fold"</code>.
In either case the effect will be used with the default duration and the default easing.
</li>
<li>
<strong>Object</strong>: If the value is an object, then <code>effect</code>, <code>duration</code>, and <code>easing</code> properties may be provided. If the <code>effect</code> property contains the name of a jQuery method, then that method will be used; otherwise it is assumed to be the name of a jQuery UI effect. When using a jQuery UI effect that supports additional settings, you may include those settings in the object and they will be passed to the effect. If <code>duration</code> or <code>easing</code> is omitted, then the default values will be used. If <code>effect</code> is omitted, then <code>"fadeOut"</code> will be used.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the tabs with the hide option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tabs({ hide: { effect: </code><code class="string">"explode"</code><code class="plain">, duration: 1000 } });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the hide option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">hide = $( </code><code class="string">".selector"</code> <code class="plain">).tabs( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"hide"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tabs( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"hide"</code><code class="plain">, { effect: </code><code class="string">"explode"</code><code class="plain">, duration: 1000 } );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-show" class="api-item">
<h3>show<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>If and how to animate the showing of the panel.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>:
When set to <code>false</code>, no animation will be used and the panel will be shown immediately.
When set to <code>true</code>, the panel will fade in with the default duration and the default easing.
</li>
<li>
<strong>Number</strong>:
The panel will fade in with the specified duration and the default easing.
</li>
<li>
<strong>String</strong>:
The panel will be shown using the specified effect.
The value can either be the name of a built-in jQuery animateion method, such as <code>"slideDown"</code>, or the name of a jQuery UI effect, such as <code>"fold"</code>.
In either case the effect will be used with the default duration and the default easing.
</li>
<li>
<strong>Object</strong>: If the value is an object, then <code>effect</code>, <code>duration</code>, and <code>easing</code> properties may be provided. If the <code>effect</code> property contains the name of a jQuery method, then that method will be used; otherwise it is assumed to be the name of a jQuery UI effect. When using a jQuery UI effect that supports additional settings, you may include those settings in the object and they will be passed to the effect. If <code>duration</code> or <code>easing</code> is omitted, then the default values will be used. If <code>effect</code> is omitted, then <code>"fadeIn"</code> will be used.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the tabs with the show option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tabs({ show: { effect: </code><code class="string">"blind"</code><code class="plain">, duration: 800 } });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the show option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">show = $( </code><code class="string">".selector"</code> <code class="plain">).tabs( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"show"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tabs( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"show"</code><code class="plain">, { effect: </code><code class="string">"blind"</code><code class="plain">, duration: 800 } );</code></div></div></td></tr></tbody></table></div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the tabs functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable">
<div class="api-item">
<h3>disable()</h3>
<div>Disables all tabs.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>disable( index )</h3>
<div>
Disables a tab. The selected tab cannot be disabled. To disable more than one tab at once, set the <a href="#option-disabled"><code>disabled</code></a> option: <code>$( "#tabs" ).tabs( "option", "disabled", [ 1, 2, 3 ] )</code>.
</div>
<ul><li>
<div><strong>index</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>Which tab to disable.</div>
</li></ul>
</div>
</div>
<div id="method-enable">
<div class="api-item">
<h3>enable()</h3>
<div>Enables all tabs.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>enable( index )</h3>
<div>Enables a tab. To enable more than one tab at once reset the disabled property like: <code>$( "#example" ).tabs( "option", "disabled", [] );</code>.</div>
<ul><li>
<div><strong>index</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>Which tab to enable.</div>
</li></ul>
</div>
</div>
<div id="method-load"><div class="api-item">
<h3>load( index )</h3>
<div>Loads the panel content of a remote tab.</div>
<ul><li>
<div><strong>index</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>Which tab to load.</div>
</li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current tabs options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the tabs option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the tabs.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-refresh"><div class="api-item">
<h3>refresh()</h3>
<div>Process any tabs that were added or removed directly in the DOM and recompute the height of the tab panels. Results depend on the content and the <a href="#option-heightStyle"><code>heightStyle</code></a> option.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the tabs container.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-activate" class="api-item first-item">
<h3>activate( event, ui )</h3>
<div>Triggered after a tab has been activated (after animation completes). If the tabs were previously collapsed, <code>ui.oldTab</code> and <code>ui.oldPanel</code> will be empty jQuery objects. If the tabs are collapsing, <code>ui.newTab</code> and <code>ui.newPanel</code> will be empty jQuery objects.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>newTab</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The tab that was just activated.</div>
</li>
<li>
<div><strong>oldTab</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The tab that was just deactivated.</div>
</li>
<li>
<div><strong>newPanel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel that was just activated.</div>
</li>
<li>
<div><strong>oldPanel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel that was just deactivated.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-beforeActivate" class="api-item">
<h3>beforeActivate( event, ui )</h3>
<div>Triggered directly after a tab is activated. Can be canceled to prevent the tab from activating. If the tabs are currently collapsed, <code>ui.oldTab</code> and <code>ui.oldPanel</code> will be empty jQuery objects. If the tabs are collapsing, <code>ui.newTab</code> and <code>ui.newPanel</code> will be empty jQuery objects.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>newTab</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The tab that is about to be activated.</div>
</li>
<li>
<div><strong>oldTab</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The tab that is about to be deactivated.</div>
</li>
<li>
<div><strong>newPanel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel that is about to be activated.</div>
</li>
<li>
<div><strong>oldPanel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel that is about to be deactivated.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-beforeLoad" class="api-item">
<h3>beforeLoad( event, ui )</h3>
<div>Triggered when a remote tab is about to be loaded, after the <a href="#event-beforeActivate"><code>beforeActivate</code></a> event. Can be canceled to prevent the tab panel from loading content; though the panel will still be activated. This event is triggered just before the Ajax request is made, so modifications can be made to <code>ui.jqXHR</code> and <code>ui.ajaxSettings</code>.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>tab</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The tab that is being loaded.</div>
</li>
<li>
<div><strong>panel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel which will be populated by the Ajax response.</div>
</li>
<li>
<div><strong>jqXHR</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jqXHR">jqXHR</a>
</div>
<div>The <code>jqXHR</code> object that is requesting the content.</div>
</li>
<li>
<div><strong>ajaxSettings</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The settings that will be used by <a href="//api.jquery.com/jQuery.ajax"><code>jQuery.ajax</code></a> to request the content.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>Triggered when the tabs are created. If the tabs are collapsed, <code>ui.tab</code> and <code>ui.panel</code> will be empty jQuery objects.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>tab</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The active tab.</div>
</li>
<li>
<div><strong>panel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The active panel.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-load" class="api-item">
<h3>load( event, ui )</h3>
<div>Triggered after a remote tab has been loaded.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>tab</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The tab that was just loaded.</div>
</li>
<li>
<div><strong>panel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel which was just populated by the Ajax response.</div>
</li>
</ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>Tabs are generally used to break content into multiple sections that can be swapped to save space, much like an accordion.</p>
<p>The content for each tab panel can be defined in-page or can be loaded via Ajax; both are handled automatically based on the <code>href</code> of the anchor associated with the tab. By default tabs are activated on click, but the events can be changed to hover via the <a href="#option-event"><code>event</code></a> option.</p>
<h3>Keyboard interaction</h3>
<p>When focus is on a tab, the following key commands are available:</p>
<ul>
<li>UP/LEFT: Move focus to the previous tab. If on first tab, moves focus to last tab. Activate focused tab after a short delay.</li>
<li>DOWN/RIGHT: Move focus to the next tab. If on last tab, moves focus to first tab. Activate focused tab after a short delay.</li>
<li>HOME: Move focus to the first tab. Activate focused tab after a short delay.</li>
<li>END: Move focus to the last tab. Activate focused tab after a short delay.</li>
<li>SPACE: Activate panel associated with focused tab.</li>
<li>ENTER: Activate or toggle panel associated with focused tab.</li>
<li>ALT+PAGE UP: Move focus to the previous tab and immediately activate.</li>
<li>ALT+PAGE DOWN: Move focus to the next tab and immediately activate.</li>
</ul>
<p>When focus is in a panel, the following key commands are available:</p>
<ul>
<li>CTRL+UP: Move focus to associated tab.</li>
<li>ALT+PAGE UP: Move focus to the previous tab and immediately activate.</li>
<li>ALT+PAGE DOWN: Move focus to the next tab and immediately activate.</li>
</ul>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Tabs</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div><div class="line number30 index29 alt1">30</div><div class="line number31 index30 alt2">31</div><div class="line number32 index31 alt1">32</div><div class="line number33 index32 alt2">33</div><div class="line number34 index33 alt1">34</div><div class="line number35 index34 alt2">35</div><div class="line number36 index35 alt1">36</div><div class="line number37 index36 alt2">37</div><div class="line number38 index37 alt1">38</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>tabs demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"tabs"</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#fragment-1"</code><code class="plain">><</code><code class="keyword">span</code><code class="plain">>One</</code><code class="keyword">span</code><code class="plain">></</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#fragment-2"</code><code class="plain">><</code><code class="keyword">span</code><code class="plain">>Two</</code><code class="keyword">span</code><code class="plain">></</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#fragment-3"</code><code class="plain">><</code><code class="keyword">span</code><code class="plain">>Three</</code><code class="keyword">span</code><code class="plain">></</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number18 index17 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"fragment-1"</code><code class="plain">></code></div><div class="line number19 index18 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">p</code><code class="plain">>First tab is active by default:</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">pre</code><code class="plain">><</code><code class="keyword">code</code><code class="plain">>$( "#tabs" ).tabs(); </</code><code class="keyword">code</code><code class="plain">></</code><code class="keyword">pre</code><code class="plain">></code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"fragment-2"</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="undefined spaces"> </code><code class="plain">Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.</code></div><div class="line number25 index24 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number26 index25 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"fragment-3"</code><code class="plain">></code></div><div class="line number27 index26 alt2"><code class="undefined spaces"> </code><code class="plain">Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.</code></div><div class="line number28 index27 alt1"><code class="undefined spaces"> </code><code class="plain">Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.</code></div><div class="line number29 index28 alt2"><code class="undefined spaces"> </code><code class="plain">Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.</code></div><div class="line number30 index29 alt1"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number31 index30 alt2"><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number32 index31 alt1"> </div><div class="line number33 index32 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number34 index33 alt1"><code class="plain">$( "#tabs" ).tabs();</code></div><div class="line number35 index34 alt2"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number36 index35 alt1"> </div><div class="line number37 index36 alt2"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number38 index37 alt1"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/tabs.html | HTML | bsd | 36,948 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI menu documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Menu Widget",
"excerpt":
"\n\t\tThemeable menu with mouse and keyboard interactions for navigation.\n\t",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-icons">icons</a></div>
<div><a href="#option-menus">menus</a></div>
<div><a href="#option-position">position</a></div>
<div><a href="#option-role">role</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-blur">blur</a></div>
<div><a href="#method-collapse">collapse</a></div>
<div><a href="#method-collapseAll">collapseAll</a></div>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-expand">expand</a></div>
<div><a href="#method-focus">focus</a></div>
<div><a href="#method-isFirstItem">isFirstItem</a></div>
<div><a href="#method-isLastItem">isLastItem</a></div>
<div><a href="#method-next">next</a></div>
<div><a href="#method-nextPage">nextPage</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-previous">previous</a></div>
<div><a href="#method-previousPage">previousPage</a></div>
<div><a href="#method-refresh">refresh</a></div>
<div><a href="#method-select">select</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-blur">blur</a></div>
<div><a href="#event-create">create</a></div>
<div><a href="#event-focus">focus</a></div>
<div><a href="#event-select">select</a></div>
</div></section><article id="menu1" class="entry widget"><h2 class="section-title">
<span>Menu Widget</span><span class="version-details">version added: 1.9</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
Themeable menu with mouse and keyboard interactions for navigation.
</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-disabled" class="api-item first-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the menu if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the menu with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).menu({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).menu( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).menu( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-icons" class="api-item">
<h3>icons<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{ submenu: "ui-icon-carat-1-e" }</code>
</div>
<div>
Icons to use for submenus, matching an icon defined by the jQuery UI CSS Framework.
<ul>
<li>submenu (string, default: "ui-icon-carat-1-e")</li>
</ul>
</div>
</div>
<div id="option-menus" class="api-item">
<h3>menus<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"ul"</code>
</div>
<div>Selector for the elements that serve as the menu container, including sub-menus.</div>
</div>
<div id="option-position" class="api-item">
<h3>position<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{ my: "top left", at: "top right" }</code>
</div>
<div>Identifies the position of submenus in relation to the associated parent menu item. The <code>of</code> option defaults to the parent menu item, but you can specify another element to position against. You can refer to the <a href="/position/">jQuery UI Position</a> utility for more details about the various options.</div>
</div>
<div id="option-role" class="api-item">
<h3>role<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"menu"</code>
</div>
<div>Customize the ARIA roles used for the menu and menu items. The default uses <code>"menuitem"</code> for items. Setting the <code>role</code> option to <code>"listbox"</code> will use <code>"option"</code> for items. If set to <code>null</code>, no roles will be set, which is useful if the menu is being controlled by another element that is maintaining focus.</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-blur"><div class="api-item first-item">
<h3>blur( [event ] )</h3>
<div>
Removes focus from a menu, resets any active element styles and triggers the menu's <a href="event-blur"><code>blur</code></a> event.
</div>
<ul><li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the menu to blur.</div>
</li></ul>
</div></div>
<div id="method-collapse"><div class="api-item">
<h3>collapse( [event ] )</h3>
<div>
Closes the currently active sub-menu.
</div>
<ul><li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the menu to collapse.</div>
</li></ul>
</div></div>
<div id="method-collapseAll"><div class="api-item">
<h3>collapseAll( [event ] [, all ] )</h3>
<div>
Closes all open sub-menus.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the menu to collapse.</div>
</li>
<li>
<div><strong>all</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Boolean">Boolean</a>
</div>
<div>Indicates whether all sub-menus should be closed or only sub-menus below and including the menu that is or contains the target of the triggering event.</div>
</li>
</ul>
</div></div>
<div id="method-destroy"><div class="api-item">
<h3>destroy()</h3>
<div>
Removes the menu functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the menu.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the menu.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-expand"><div class="api-item">
<h3>expand( [event ] )</h3>
<div>
Opens the sub-menu below the currently active item, if one exists.
</div>
<ul><li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the menu to expand.</div>
</li></ul>
</div></div>
<div id="method-focus"><div class="api-item">
<h3>focus( [event ] [, item ] )</h3>
<div>
Activates a particular menu item, begins opening any sub-menu if present and triggers the menu's <a href="#event-focus"><code>focus</code></a> event.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the menu item to gain focus.</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The menu item to focus/activate.</div>
</li>
</ul>
</div></div>
<div id="method-isFirstItem"><div class="api-item">
<h3>isFirstItem()</h3>
<div>
Returns a boolean value stating whether or not the currently active item is the first item in the menu.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-isLastItem"><div class="api-item">
<h3>isLastItem()</h3>
<div>
Returns a boolean value stating whether or not the currently active item is the last item in the menu.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-next"><div class="api-item">
<h3>next( [event ] )</h3>
<div>
Moves active state to next menu item.
</div>
<ul><li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the focus to move.</div>
</li></ul>
</div></div>
<div id="method-nextPage"><div class="api-item">
<h3>nextPage( [event ] )</h3>
<div>
Moves active state to first menu item below the bottom of a scrollable menu or the last item if not scrollable.
</div>
<ul><li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the focus to move.</div>
</li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current menu options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the menu option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the menu.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-previous"><div class="api-item">
<h3>previous( [event ] )</h3>
<div>
Moves active state to previous menu item.
</div>
<ul><li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the focus to move.</div>
</li></ul>
</div></div>
<div id="method-previousPage"><div class="api-item">
<h3>previousPage( [event ] )</h3>
<div>
Moves active state to first menu item above the top of a scrollable menu or the first item if not scrollable.
</div>
<ul><li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the focus to move.</div>
</li></ul>
</div></div>
<div id="method-refresh"><div class="api-item">
<h3>refresh()</h3>
<div>
Initializes sub-menus and menu items that have not already been initialized. New menu items, including sub-menus can be added to the menu or all of the contents of the menu can be replaced and then initialized with the <code>refresh()</code> method.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-select"><div class="api-item">
<h3>select( [event ] )</h3>
<div>
Selects the currently active menu item, collapses all sub-menus and triggers the menu's <a href="#event-select"><code>select</code></a> event.
</div>
<ul><li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>What triggered the selection.</div>
</li></ul>
</div></div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the menu.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-blur" class="api-item first-item">
<h3>blur( event, ui )</h3>
<div>
Triggered when the menu loses focus.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>
The currently active menu item.
</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the menu is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-focus" class="api-item">
<h3>focus( event, ui )</h3>
<div>
Triggered when a menu gains focus or when any menu item is activated.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>
The currently active menu item.
</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-select" class="api-item">
<h3>select( event, ui )</h3>
<div>
Triggered when a menu item is selected.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>
The currently active menu item.
</div>
</li></ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>A menu can be created from any valid markup as long as the elements have a strict parent/child relationship and each menu item has an anchor. The most commonly used element is the unordered list (<code><ul></code>):</p>
<pre>
<ul id="menu">
<li><a href="#">Item 1</a></li>
<li><a href="#">Item 2</a></li>
<li><a href="#">Item 3</a>
<ul>
<li><a href="#">Item 3-1</a></li>
<li><a href="#">Item 3-2</a></li>
<li><a href="#">Item 3-3</a></li>
<li><a href="#">Item 3-4</a></li>
<li><a href="#">Item 3-5</a></li>
</ul>
</li>
<li><a href="#">Item 4</a></li>
<li><a href="#">Item 5</a></li>
</ul>
</pre>
<p>If you use a structure other than <code><ul></code>/<code><li></code>, including using the same element for the menu and the menu items, use the <a href="#option-menus"><code>menus</code></a> option to specify a way to differentiate the two elements, e.g., <code>menus: "div.menuElement"</code>.</p>
<p>Any menu item can be disabled by adding the <code>ui-state-disabled</code> class to that element.</p>
<p>To add icons to the menu, include them in the markup:</p>
<pre>
<ul id="menu">
<li><a href="#"><span class="ui-icon ui-icon-disk"></span>Save</a></li>
</ul>
</pre>
<p>Menu automatically adds the necessary padding to items without icons.</p>
<h3>Keyboard interaction</h3>
<ul>
<li>ENTER/SPACE: Invoke the focused menu item's action, which may be opening a submenu.</li>
<li>UP: Move focus to the previous menu item.</li>
<li>DOWN: Move focus to the next menu item.</li>
<li>RIGHT: Open the submenu, if available.</li>
<li>LEFT: Close the current submenu and move focus to the parent menu item. If not in a submenu, do nothing.</li>
<li>ESCAPE: Close the current submenu and move focus to the parent menu item. If not in a submenu, do nothing.</li>
</ul>
<p>Typing a letter moves focus to the first item whose title starts with that character. Repeating the same character cycles through matching items. Typing more characters within the one second timer matches those characters.</p>
<p>Disabled items can receive keyboard focus, but do not allow any other interaction.</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Menu</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div><div class="line number30 index29 alt1">30</div><div class="line number31 index30 alt2">31</div><div class="line number32 index31 alt1">32</div><div class="line number33 index32 alt2">33</div><div class="line number34 index33 alt1">34</div><div class="line number35 index34 alt2">35</div><div class="line number36 index35 alt1">36</div><div class="line number37 index36 alt2">37</div><div class="line number38 index37 alt1">38</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>menu demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">.ui-menu {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 200px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number16 index15 alt1"> </div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">ul</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"menu"</code><code class="plain">></code></div><div class="line number18 index17 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 1</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number19 index18 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 2</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 3</</code><code class="keyword">a</code><code class="plain">></code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 3-1</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 3-2</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 3-3</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number25 index24 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 3-4</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number26 index25 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 3-5</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number27 index26 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number28 index27 alt1"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 4</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number30 index29 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code><code class="plain">>Item 5</</code><code class="keyword">a</code><code class="plain">></</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number31 index30 alt2"><code class="plain"></</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number32 index31 alt1"> </div><div class="line number33 index32 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number34 index33 alt1"><code class="plain">$( "#menu" ).menu();</code></div><div class="line number35 index34 alt2"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number36 index35 alt1"> </div><div class="line number37 index36 alt2"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number38 index37 alt1"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/menu.html | HTML | bsd | 32,437 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI datepicker documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Datepicker Widget",
"excerpt":
"Select a date from a popup or inline calendar",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-altField">altField</a></div>
<div><a href="#option-altFormat">altFormat</a></div>
<div><a href="#option-appendText">appendText</a></div>
<div><a href="#option-autoSize">autoSize</a></div>
<div><a href="#option-buttonImage">buttonImage</a></div>
<div><a href="#option-buttonImageOnly">buttonImageOnly</a></div>
<div><a href="#option-buttonText">buttonText</a></div>
<div><a href="#option-calculateWeek">calculateWeek</a></div>
<div><a href="#option-changeMonth">changeMonth</a></div>
<div><a href="#option-changeYear">changeYear</a></div>
<div><a href="#option-closeText">closeText</a></div>
<div><a href="#option-constrainInput">constrainInput</a></div>
<div><a href="#option-currentText">currentText</a></div>
<div><a href="#option-dateFormat">dateFormat</a></div>
<div><a href="#option-dayNames">dayNames</a></div>
<div><a href="#option-dayNamesMin">dayNamesMin</a></div>
<div><a href="#option-dayNamesShort">dayNamesShort</a></div>
<div><a href="#option-defaultDate">defaultDate</a></div>
<div><a href="#option-duration">duration</a></div>
<div><a href="#option-firstDay">firstDay</a></div>
<div><a href="#option-gotoCurrent">gotoCurrent</a></div>
<div><a href="#option-hideIfNoPrevNext">hideIfNoPrevNext</a></div>
<div><a href="#option-isRTL">isRTL</a></div>
<div><a href="#option-maxDate">maxDate</a></div>
<div><a href="#option-minDate">minDate</a></div>
<div><a href="#option-monthNames">monthNames</a></div>
<div><a href="#option-monthNamesShort">monthNamesShort</a></div>
<div><a href="#option-navigationAsDateFormat">navigationAsDateFormat</a></div>
<div><a href="#option-nextText">nextText</a></div>
<div><a href="#option-numberOfMonths">numberOfMonths</a></div>
<div><a href="#option-prevText">prevText</a></div>
<div><a href="#option-selectOtherMonths">selectOtherMonths</a></div>
<div><a href="#option-shortYearCutoff">shortYearCutoff</a></div>
<div><a href="#option-showAnim">showAnim</a></div>
<div><a href="#option-showButtonPanel">showButtonPanel</a></div>
<div><a href="#option-showCurrentAtPos">showCurrentAtPos</a></div>
<div><a href="#option-showMonthAfterYear">showMonthAfterYear</a></div>
<div><a href="#option-showOn">showOn</a></div>
<div><a href="#option-showOptions">showOptions</a></div>
<div><a href="#option-showOtherMonths">showOtherMonths</a></div>
<div><a href="#option-showWeek">showWeek</a></div>
<div><a href="#option-stepMonths">stepMonths</a></div>
<div><a href="#option-weekHeader">weekHeader</a></div>
<div><a href="#option-yearRange">yearRange</a></div>
<div><a href="#option-yearSuffix">yearSuffix</a></div>
<div><a href="#option-beforeShow">beforeShow</a></div>
<div><a href="#option-beforeShowDay">beforeShowDay</a></div>
<div><a href="#option-onChangeMonthYear">onChangeMonthYear</a></div>
<div><a href="#option-onClose">onClose</a></div>
<div><a href="#option-onSelect">onSelect</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-dialog">dialog</a></div>
<div><a href="#method-isDisabled">isDisabled</a></div>
<div><a href="#method-hide">hide</a></div>
<div><a href="#method-show">show</a></div>
<div><a href="#method-refresh">refresh</a></div>
<div><a href="#method-getDate">getDate</a></div>
<div><a href="#method-setDate">setDate</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section"><h3>Events</h3></div></section><article id="datepicker1" class="entry widget"><h2 class="section-title">
<span>Datepicker Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Select a date from a popup or inline calendar</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-altField" class="api-item first-item">
<h3>altField<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#jQuery">jQuery</a> or <a href="http://api.jquery.com/Types#Element">Element</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>""</code>
</div>
<div>An input element that is to be updated with the selected date from the datepicker. Use the <a href="#option-altFormat"><code>altFormat</code></a> option to change the format of the date within this field. Leave as blank for no alternate field.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the altField option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ altField: </code><code class="string">"#actualDate"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the altField option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">altField = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"altField"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"altField"</code><code class="plain">, </code><code class="string">"#actualDate"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-altFormat" class="api-item">
<h3>altFormat<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>""</code>
</div>
<div>The <a href="#option-dateFormat"><code>dateFormat</code></a> to be used for the <a href="#option-altField"><code>altField</code></a> option. This allows one date format to be shown to the user for selection purposes, while a different format is actually sent behind the scenes. For a full list of the possible formats see the [[UI/Datepicker/formatDate|formatDate]] function</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the altFormat option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ altFormat: </code><code class="string">"yy-mm-dd"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the altFormat option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">altFormat = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"altFormat"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"altFormat"</code><code class="plain">, </code><code class="string">"yy-mm-dd"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-appendText" class="api-item">
<h3>appendText<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>""</code>
</div>
<div>The text to display after each date field, e.g., to show the required format.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the appendText option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ appendText: </code><code class="string">"(yyyy-mm-dd)"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the appendText option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">appendText = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"appendText"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"appendText"</code><code class="plain">, </code><code class="string">"(yyyy-mm-dd)"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-autoSize" class="api-item">
<h3>autoSize<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Set to <code>true</code> to automatically resize the input field to accommodate dates in the current <a href="#option-dateFormat"><code>dateFormat</code></a>.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the autoSize option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ autoSize: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the autoSize option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">autoSize = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"autoSize"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"autoSize"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-beforeShow" class="api-item">
<h3>beforeShow<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types/#Function">Function</a>( <a href="http://api.jquery.com/Types#Element">Element</a> input, <a href="http://api.jquery.com/Types#Object">Object</a> inst )</span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>A function that takes an input field and current datepicker instance and returns an options object to update the datepicker with. It is called just before the datepicker is displayed.</div>
</div>
<div id="option-beforeShowDay" class="api-item">
<h3>beforeShowDay<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types/#Function">Function</a>( <a href="http://api.jquery.com/Types#Date">Date</a> date )</span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>A function takes a date as a parameter and must return an array with <code>[0]</code> equal to <code>true</code>/<code>false</code> indicating whether or not this date is selectable, <code>[1]</code> equal to a CSS class name or <code>""</code> for the default presentation, and <code>[2]</code> an optional popup tooltip for this date. It is called for each day in the datepicker before it is displayed.</div>
</div>
<div id="option-buttonImage" class="api-item">
<h3>buttonImage<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>""</code>
</div>
<div>The URL for the popup button image. If set, the <a href="#option-buttonText"><code>buttonText</code></a> option becomes the <code>alt</code> value and is not directly displayed.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the buttonImage option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ buttonImage: </code><code class="string">"/images/datepicker.gif"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the buttonImage option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">buttonImage = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"buttonImage"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"buttonImage"</code><code class="plain">, </code><code class="string">"/images/datepicker.gif"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-buttonImageOnly" class="api-item">
<h3>buttonImageOnly<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the button image should be rendered by itself instead of inside a button element.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the buttonImageOnly option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ buttonImageOnly: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the buttonImageOnly option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">buttonImageOnly = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"buttonImageOnly"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"buttonImageOnly"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-buttonText" class="api-item">
<h3>buttonText<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"..."</code>
</div>
<div>The text to display on the trigger button. Use in conjunction with the <a href="#option-showOn"><code>showOn</code></a> option set to <code>"button"</code> or <code>"both"</code>.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the buttonText option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ buttonText: </code><code class="string">"Choose"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the buttonText option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">buttonText = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"buttonText"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"buttonText"</code><code class="plain">, </code><code class="string">"Choose"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-calculateWeek" class="api-item">
<h3>calculateWeek<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types/#Function">Function</a>()</span>
</h3>
<div class="default">
<strong>Default: </strong><code>jQuery.datepicker.iso8601Week</code>
</div>
<div>A function to calculate the week of the year for a given date. The default implementation uses the ISO 8601 definition: weeks start on a Monday; the first week of the year contains the first Thursday of the year.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the calculateWeek option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ calculateWeek: myWeekCalc });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the calculateWeek option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">calculateWeek = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"calculateWeek"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"calculateWeek"</code><code class="plain">, myWeekCalc );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-changeMonth" class="api-item">
<h3>changeMonth<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the month should be rendered as a dropdown instead of text.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the changeMonth option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ changeMonth: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the changeMonth option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">changeMonth = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"changeMonth"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"changeMonth"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-changeYear" class="api-item">
<h3>changeYear<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the year should be rendered as a dropdown instead of text. Use the <a href="#option-yearRange"><code>yearRange</code></a> option to control which years are made available for selection.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the changeYear option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ changeYear: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the changeYear option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">changeYear = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"changeYear"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"changeYear"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-closeText" class="api-item">
<h3>closeText<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"Done"</code>
</div>
<div>The text to display for the close link. Use the <a href="#option-showButtonPanel"><code>showButtonPanel</code></a> option to display this button.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the closeText option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ closeText: </code><code class="string">"Close"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the closeText option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">closeText = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"closeText"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"closeText"</code><code class="plain">, </code><code class="string">"Close"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-constrainInput" class="api-item">
<h3>constrainInput<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>When <code>true</code>, entry in the input field is constrained to those characters allowed by the current <a href="#option-dateFormat"><code>dateFormat</code></a> option.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the constrainInput option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ constrainInput: </code><code class="keyword">false</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the constrainInput option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">constrainInput = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"constrainInput"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"constrainInput"</code><code class="plain">, </code><code class="keyword">false</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-currentText" class="api-item">
<h3>currentText<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"Today"</code>
</div>
<div>The text to display for the current day link. Use the <a href="#option-showButtonPanel"><code>showButtonPanel</code></a> option to display this button.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the currentText option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ currentText: </code><code class="string">"Now"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the currentText option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">currentText = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"currentText"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"currentText"</code><code class="plain">, </code><code class="string">"Now"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-dateFormat" class="api-item">
<h3>dateFormat<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"mm/dd/yy"</code>
</div>
<div>The format for parsed and displayed dates. For a full list of the possible formats see the <code>[[UI/Datepicker/formatDate|formatDate]]</code> function.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the dateFormat option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ dateFormat: </code><code class="string">"yy-mm-dd"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the dateFormat option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">dateFormat = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"dateFormat"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"dateFormat"</code><code class="plain">, </code><code class="string">"yy-mm-dd"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-dayNames" class="api-item">
<h3>dayNames<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>[ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" ]</code>
</div>
<div>The list of long day names, starting from Sunday, for use as requested via the <a href="#option-dateFormat"><code>dateFormat</code></a> option.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the dayNames option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ dayNames: [ </code><code class="string">"Dimanche"</code><code class="plain">, </code><code class="string">"Lundi"</code><code class="plain">, </code><code class="string">"Mardi"</code><code class="plain">, </code><code class="string">"Mercredi"</code><code class="plain">, </code><code class="string">"Jeudi"</code><code class="plain">, </code><code class="string">"Vendredi"</code><code class="plain">, </code><code class="string">"Samedi"</code> <code class="plain">] });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the dayNames option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">dayNames = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"dayNames"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"dayNames"</code><code class="plain">, [ </code><code class="string">"Dimanche"</code><code class="plain">, </code><code class="string">"Lundi"</code><code class="plain">, </code><code class="string">"Mardi"</code><code class="plain">, </code><code class="string">"Mercredi"</code><code class="plain">, </code><code class="string">"Jeudi"</code><code class="plain">, </code><code class="string">"Vendredi"</code><code class="plain">, </code><code class="string">"Samedi"</code> <code class="plain">] );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-dayNamesMin" class="api-item">
<h3>dayNamesMin<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>[ "Su", "Mo", "Tu", "We", "Th", "Fr", "Sa" ]</code>
</div>
<div>The list of minimised day names, starting from Sunday, for use as column headers within the datepicker.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the dayNamesMin option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ dayNamesMin: [ </code><code class="string">"Di"</code><code class="plain">, </code><code class="string">"Lu"</code><code class="plain">, </code><code class="string">"Ma"</code><code class="plain">, </code><code class="string">"Me"</code><code class="plain">, </code><code class="string">"Je"</code><code class="plain">, </code><code class="string">"Ve"</code><code class="plain">, </code><code class="string">"Sa"</code> <code class="plain">] });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the dayNamesMin option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">dayNamesMin = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"dayNamesMin"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"dayNamesMin"</code><code class="plain">, [ </code><code class="string">"Di"</code><code class="plain">, </code><code class="string">"Lu"</code><code class="plain">, </code><code class="string">"Ma"</code><code class="plain">, </code><code class="string">"Me"</code><code class="plain">, </code><code class="string">"Je"</code><code class="plain">, </code><code class="string">"Ve"</code><code class="plain">, </code><code class="string">"Sa"</code> <code class="plain">] );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-dayNamesShort" class="api-item">
<h3>dayNamesShort<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>[ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ]</code>
</div>
<div>The list of abbreviated day names, starting from Sunday, for use as requested via the <a href="#option-dateFormat"><code>dateFormat</code></a> option.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the dayNamesShort option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ dayNamesShort: [ </code><code class="string">"Dim"</code><code class="plain">, </code><code class="string">"Lun"</code><code class="plain">, </code><code class="string">"Mar"</code><code class="plain">, </code><code class="string">"Mer"</code><code class="plain">, </code><code class="string">"Jeu"</code><code class="plain">, </code><code class="string">"Ven"</code><code class="plain">, </code><code class="string">"Sam"</code> <code class="plain">] });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the dayNamesShort option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">dayNamesShort = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"dayNamesShort"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"dayNamesShort"</code><code class="plain">, [ </code><code class="string">"Dim"</code><code class="plain">, </code><code class="string">"Lun"</code><code class="plain">, </code><code class="string">"Mar"</code><code class="plain">, </code><code class="string">"Mer"</code><code class="plain">, </code><code class="string">"Jeu"</code><code class="plain">, </code><code class="string">"Ven"</code><code class="plain">, </code><code class="string">"Sam"</code> <code class="plain">] );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-defaultDate" class="api-item">
<h3>defaultDate<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Date">Date</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>Set the date to highlight on first opening if the field is blank. Specify either an actual date via a Date object or as a string in the current <code>[[UI/Datepicker#option-dateFormat|dateFormat]]</code>, or a number of days from today (e.g. +7) or a string of values and periods ('y' for years, 'm' for months, 'w' for weeks, 'd' for days, e.g. '+1m +7d'), or null for today.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Date</strong>: A date object containing the default date.</li>
<li>
<strong>Number</strong>: A number of days from today. For example <code>2</code> represents two days from today and <code>-1</code> represents yesterday.</li>
<li>
<strong>String</strong>: A string in the format defined by the <a href="#option-dateFormat"><code>dateFormat</code></a> option, or a relative date. Relative dates must contain value and period pairs; valid periods are <code>"y"</code> for years, <code>"m"</code> for months, <code>"w"</code> for weeks, and <code>"d"</code> for days. For example, <code>"+1m +7d"</code> represents one month and seven days from today.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the datepicker with the defaultDate option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ defaultDate: +7 });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the defaultDate option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">defaultDate = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"defaultDate"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"defaultDate"</code><code class="plain">, +7 );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-duration" class="api-item">
<h3>duration<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#"></a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"normal"</code>
</div>
<div>Control the speed at which the datepicker appears, it may be a time in milliseconds or a string representing one of the three predefined speeds ("slow", "normal", "fast").</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the duration option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ duration: </code><code class="string">"slow"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the duration option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">duration = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"duration"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"duration"</code><code class="plain">, </code><code class="string">"slow"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-firstDay" class="api-item">
<h3>firstDay<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>Set the first day of the week: Sunday is <code>0</code>, Monday is <code>1</code>, etc.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the firstDay option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ firstDay: 1 });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the firstDay option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">firstDay = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"firstDay"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"firstDay"</code><code class="plain">, 1 );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-gotoCurrent" class="api-item">
<h3>gotoCurrent<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>When <code>true</code>, the current day link moves to the currently selected date instead of today.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the gotoCurrent option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ gotoCurrent: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the gotoCurrent option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">gotoCurrent = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"gotoCurrent"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"gotoCurrent"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-hideIfNoPrevNext" class="api-item">
<h3>hideIfNoPrevNext<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Normally the previous and next links are disabled when not applicable (see the <a href="#option-minDate"><code>minDate</code></a> and <a href="#option-maxDate"><code>maxDate</code></a> options). You can hide them altogether by setting this attribute to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the hideIfNoPrevNext option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ hideIfNoPrevNext: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the hideIfNoPrevNext option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">hideIfNoPrevNext = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"hideIfNoPrevNext"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"hideIfNoPrevNext"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-isRTL" class="api-item">
<h3>isRTL<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the current language is drawn from right to left.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the isRTL option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ isRTL: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the isRTL option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">isRTL = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"isRTL"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"isRTL"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-maxDate" class="api-item">
<h3>maxDate<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Date">Date</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>The maximum selectable date. When set to <code>null</code>, there is no maximum.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Date</strong>: A date object containing the maximum date.</li>
<li>
<strong>Number</strong>: A number of days from today. For example <code>2</code> represents two days from today and <code>-1</code> represents yesterday.</li>
<li>
<strong>String</strong>: A string in the format defined by the <a href="#option-dateFormat"><code>dateFormat</code></a> option, or a relative date. Relative dates must contain value and period pairs; valid periods are <code>"y"</code> for years, <code>"m"</code> for months, <code>"w"</code> for weeks, and <code>"d"</code> for days. For example, <code>"+1m +7d"</code> represents one month and seven days from today.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the datepicker with the maxDate option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ maxDate: </code><code class="string">"+1m +1w"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the maxDate option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">maxDate = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"maxDate"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"maxDate"</code><code class="plain">, </code><code class="string">"+1m +1w"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-minDate" class="api-item">
<h3>minDate<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Date">Date</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>The minimum selectable date. When set to <code>null</code>, there is no minimum.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Date</strong>: A date object containing the minimum date.</li>
<li>
<strong>Number</strong>: A number of days from today. For example <code>2</code> represents two days from today and <code>-1</code> represents yesterday.</li>
<li>
<strong>String</strong>: A string in the format defined by the <a href="#option-dateFormat"><code>dateFormat</code></a> option, or a relative date. Relative dates must contain value and period pairs; valid periods are <code>"y"</code> for years, <code>"m"</code> for months, <code>"w"</code> for weeks, and <code>"d"</code> for days. For example, <code>"+1m +7d"</code> represents one month and seven days from today.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the datepicker with the minDate option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ minDate: </code><code class="keyword">new</code> <code class="plain">Date(2007, 1 - 1, 1) });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the minDate option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">minDate = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"minDate"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"minDate"</code><code class="plain">, </code><code class="keyword">new</code> <code class="plain">Date(2007, 1 - 1, 1) );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-monthNames" class="api-item">
<h3>monthNames<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>[ "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ]</code>
</div>
<div>The list of full month names, for use as requested via the <a href="#option-dateFormat"><code>dateFormat</code></a> option.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the monthNames option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ monthNames: [ </code><code class="string">"Januar"</code><code class="plain">, </code><code class="string">"Februar"</code><code class="plain">, </code><code class="string">"Marts"</code><code class="plain">, </code><code class="string">"April"</code><code class="plain">, </code><code class="string">"Maj"</code><code class="plain">, </code><code class="string">"Juni"</code><code class="plain">, </code><code class="string">"Juli"</code><code class="plain">, </code><code class="string">"August"</code><code class="plain">, </code><code class="string">"September"</code><code class="plain">, </code><code class="string">"Oktober"</code><code class="plain">, </code><code class="string">"November"</code><code class="plain">, </code><code class="string">"December"</code> <code class="plain">] });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the monthNames option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">monthNames = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"monthNames"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"monthNames"</code><code class="plain">, [ </code><code class="string">"Januar"</code><code class="plain">, </code><code class="string">"Februar"</code><code class="plain">, </code><code class="string">"Marts"</code><code class="plain">, </code><code class="string">"April"</code><code class="plain">, </code><code class="string">"Maj"</code><code class="plain">, </code><code class="string">"Juni"</code><code class="plain">, </code><code class="string">"Juli"</code><code class="plain">, </code><code class="string">"August"</code><code class="plain">, </code><code class="string">"September"</code><code class="plain">, </code><code class="string">"Oktober"</code><code class="plain">, </code><code class="string">"November"</code><code class="plain">, </code><code class="string">"December"</code> <code class="plain">] );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-monthNamesShort" class="api-item">
<h3>monthNamesShort<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>[ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ]</code>
</div>
<div>The list of abbreviated month names, as used in the month header on each datepicker and as requested via the <a href="#option-dateFormat"><code>dateFormat</code></a> option.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the monthNamesShort option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ monthNamesShort: [ </code><code class="string">"Jan"</code><code class="plain">, </code><code class="string">"Feb"</code><code class="plain">, </code><code class="string">"Mar"</code><code class="plain">, </code><code class="string">"Apr"</code><code class="plain">, </code><code class="string">"Maj"</code><code class="plain">, </code><code class="string">"Jun"</code><code class="plain">, </code><code class="string">"Jul"</code><code class="plain">, </code><code class="string">"Aug"</code><code class="plain">, </code><code class="string">"Sep"</code><code class="plain">, </code><code class="string">"Okt"</code><code class="plain">, </code><code class="string">"Nov"</code><code class="plain">, </code><code class="string">"Dec"</code> <code class="plain">] });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the monthNamesShort option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">monthNamesShort = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"monthNamesShort"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"monthNamesShort"</code><code class="plain">, [ </code><code class="string">"Jan"</code><code class="plain">, </code><code class="string">"Feb"</code><code class="plain">, </code><code class="string">"Mar"</code><code class="plain">, </code><code class="string">"Apr"</code><code class="plain">, </code><code class="string">"Maj"</code><code class="plain">, </code><code class="string">"Jun"</code><code class="plain">, </code><code class="string">"Jul"</code><code class="plain">, </code><code class="string">"Aug"</code><code class="plain">, </code><code class="string">"Sep"</code><code class="plain">, </code><code class="string">"Okt"</code><code class="plain">, </code><code class="string">"Nov"</code><code class="plain">, </code><code class="string">"Dec"</code> <code class="plain">] );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-navigationAsDateFormat" class="api-item">
<h3>navigationAsDateFormat<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the <a href="#option-prevText"><code>prevText</code></a> and <a href="#option-nextText"><code>nextText</code></a> options should be parsed as dates by the <code>[[UI/Datepicker/formatDate|formatDate]]</code> function, allowing them to display the target month names for example.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the navigationAsDateFormat option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ navigationAsDateFormat: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the navigationAsDateFormat option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">navigationAsDateFormat = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"navigationAsDateFormat"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"navigationAsDateFormat"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-nextText" class="api-item">
<h3>nextText<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"Next"</code>
</div>
<div>The text to display for the next month link. With the standard ThemeRoller styling, this value is replaced by an icon.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the nextText option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ nextText: </code><code class="string">"Later"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the nextText option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">nextText = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"nextText"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"nextText"</code><code class="plain">, </code><code class="string">"Later"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-numberOfMonths" class="api-item">
<h3>numberOfMonths<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1</code>
</div>
<div>The number of months to show at once.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>: The number of months to display in a single row.</li>
<li>
<strong>Array</strong>: An array defining the number of rows and columns to display.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the datepicker with the numberOfMonths option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ numberOfMonths: [ 2, 3 ] });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the numberOfMonths option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">numberOfMonths = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"numberOfMonths"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"numberOfMonths"</code><code class="plain">, [ 2, 3 ] );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-onChangeMonthYear" class="api-item">
<h3>onChangeMonthYear<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types/#Function">Function</a>( <a href="http://api.jquery.com/Types#Integer">Integer</a> year, <a href="http://api.jquery.com/Types#Integer">Integer</a> month, <a href="http://api.jquery.com/Types#Object">Object</a> inst )</span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>Called when the datepicker moves to a new month and/or year. The function receives the selected year, month (1-12), and the datepicker instance as parameters. <code>this</code> refers to the associated input field.</div>
</div>
<div id="option-onClose" class="api-item">
<h3>onClose<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types/#Function">Function</a>( <a href="http://api.jquery.com/Types#String">String</a> dateText, <a href="http://api.jquery.com/Types#Object">Object</a> inst )</span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>Called when the datepicker is closed, whether or not a date is selected. The function receives the selected date as text (<code>""</code> if none) and the datepicker instance as parameters. <code>this</code> refers to the associated input field.</div>
</div>
<div id="option-onSelect" class="api-item">
<h3>onSelect<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types/#Function">Function</a>( <a href="http://api.jquery.com/Types#String">String</a> dateText, <a href="http://api.jquery.com/Types#Object">Object</a> inst )</span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>Called when the datepicker is selected. The function receives the selected date as text and the datepicker instance as parameters. <code>this</code> refers to the associated input field.</div>
</div>
<div id="option-prevText" class="api-item">
<h3>prevText<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"Prev"</code>
</div>
<div>The text to display for the previous month link. With the standard ThemeRoller styling, this value is replaced by an icon.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the prevText option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ prevText: </code><code class="string">"Earlier"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the prevText option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">prevText = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"prevText"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"prevText"</code><code class="plain">, </code><code class="string">"Earlier"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-selectOtherMonths" class="api-item">
<h3>selectOtherMonths<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether days in other months shown before or after the current month are selectable. This only applies if the <a href="#option-showOtherMonths"><code>showOtherMonths</code></a> option is set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the selectOtherMonths option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ selectOtherMonths: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the selectOtherMonths option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">selectOtherMonths = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"selectOtherMonths"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"selectOtherMonths"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-shortYearCutoff" class="api-item">
<h3>shortYearCutoff<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"+10"</code>
</div>
<div>The cutoff year for determining the century for a date (used in conjunction with <code>[[UI/Datepicker#option-dateFormat|dateFormat]]</code> 'y'). Any dates entered with a year value less than or equal to the cutoff year are considered to be in the current century, while those greater than it are deemed to be in the previous century.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>: A value between <code>0</code> and <code>99</code> indicating the cutoff year.</li>
<li>
<strong>String</strong>: A relative number of years from the current year, e.g., <code>"+3"</code> or <code>"-5"</code>.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the datepicker with the shortYearCutoff option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ shortYearCutoff: 50 });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the shortYearCutoff option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">shortYearCutoff = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"shortYearCutoff"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"shortYearCutoff"</code><code class="plain">, 50 );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-showAnim" class="api-item">
<h3>showAnim<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"show"</code>
</div>
<div>The name of the animation used to show and hide the datepicker. Use <code>"show"</code> (the default), <code>"slideDown"</code>, <code>"fadeIn"</code>, any of the <a href="/category/effects/">jQuery UI effects</a>. Set to an empty string to disable animation.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the showAnim option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ showAnim: </code><code class="string">"fold"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the showAnim option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">showAnim = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showAnim"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showAnim"</code><code class="plain">, </code><code class="string">"fold"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-showButtonPanel" class="api-item">
<h3>showButtonPanel<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether to show the button panel.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the showButtonPanel option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ showButtonPanel: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the showButtonPanel option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">showButtonPanel = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showButtonPanel"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showButtonPanel"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-showCurrentAtPos" class="api-item">
<h3>showCurrentAtPos<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>When displaying multiple months via the <a href="#option-numberOfMonths"><code>numberOfMonths</code></a> option, the <code>showCurrentAtPos</code> option defines which position to display the current month in.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the showCurrentAtPos option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ showCurrentAtPos: 3 });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the showCurrentAtPos option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">showCurrentAtPos = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showCurrentAtPos"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showCurrentAtPos"</code><code class="plain">, 3 );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-showMonthAfterYear" class="api-item">
<h3>showMonthAfterYear<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether to show the month after the year in the header.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the showMonthAfterYear option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ showMonthAfterYear: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the showMonthAfterYear option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">showMonthAfterYear = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showMonthAfterYear"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showMonthAfterYear"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-showOn" class="api-item">
<h3>showOn<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"focus"</code>
</div>
<div>When the datepicker should appear. The datepicker can appear when the field receives focus (<code>"focus"</code>), when a button is clicked (<code>"button"</code>), or when either event occurs (<code>"both"</code>).</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the showOn option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ showOn: </code><code class="string">"both"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the showOn option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">showOn = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showOn"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showOn"</code><code class="plain">, </code><code class="string">"both"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-showOptions" class="api-item">
<h3>showOptions<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{}</code>
</div>
<div>If using one of the jQuery UI effects for the <a href="#option-showAnim"><code>showAnim</code></a> option, you can provide additional settings for that animation via this option.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the showOptions option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ showOptions: { direction: </code><code class="string">"up"</code> <code class="plain">} });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the showOptions option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">showOptions = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showOptions"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showOptions"</code><code class="plain">, { direction: </code><code class="string">"up"</code> <code class="plain">} );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-showOtherMonths" class="api-item">
<h3>showOtherMonths<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether to display dates in other months (non-selectable) at the start or end of the current month. To make these days selectable use the <a href="#option-selectOtherMonths"><code>selectOtherMonths</code></a> option.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the showOtherMonths option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ showOtherMonths: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the showOtherMonths option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">showOtherMonths = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showOtherMonths"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showOtherMonths"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-showWeek" class="api-item">
<h3>showWeek<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>When <code>true</code>, a column is added to show the week of the year. The <a href="#option-calculateWeek"><code>calculateWeek</code></a> option determines how the week of the year is calculated. You may also want to change the <a href="#option-firstDay"><code>firstDay</code></a> option.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the showWeek option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ showWeek: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the showWeek option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">showWeek = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showWeek"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"showWeek"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-stepMonths" class="api-item">
<h3>stepMonths<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1</code>
</div>
<div>Set how many months to move when clicking the previous/next links.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the stepMonths option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ stepMonths: 3 });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the stepMonths option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">stepMonths = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"stepMonths"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"stepMonths"</code><code class="plain">, 3 );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-weekHeader" class="api-item">
<h3>weekHeader<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"Wk"</code>
</div>
<div>The text to display for the week of the year column heading. Use the <a href="#option-showWeek"><code>showWeek</code></a> option to display this column.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the weekHeader option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ weekHeader: </code><code class="string">"W"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the weekHeader option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">weekHeader = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"weekHeader"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"weekHeader"</code><code class="plain">, </code><code class="string">"W"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-yearRange" class="api-item">
<h3>yearRange<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"c-10:c+10"</code>
</div>
<div>The range of years displayed in the year drop-down: either relative to today's year (<code>"-nn:+nn"</code>), relative to the currently selected year (<code>"c-nn:c+nn"</code>), absolute (<code>"nnnn:nnnn"</code>), or combinations of these formats (<code>"nnnn:-nn"</code>). Note that this option only affects what appears in the drop-down, to restrict which dates may be selected use the <a href="#option-minDate"><code>minDate</code></a> and/or <a href="#option-maxDate"><code>maxDate</code></a> options.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the yearRange option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ yearRange: </code><code class="string">"2002:2012"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the yearRange option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">yearRange = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"yearRange"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"yearRange"</code><code class="plain">, </code><code class="string">"2002:2012"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-yearSuffix" class="api-item">
<h3>yearSuffix<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>""</code>
</div>
<div>Additional text to display after the year in the month headers.</div>
<strong>Code examples:</strong><p>Initialize the datepicker with the yearSuffix option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker({ yearSuffix: </code><code class="string">"CE"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the yearSuffix option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">yearSuffix = $( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"yearSuffix"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).datepicker( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"yearSuffix"</code><code class="plain">, </code><code class="string">"CE"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the datepicker functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-dialog"><div class="api-item">
<h3>dialog( date [, onSelect ] [, settings ] [, pos ] )</h3>
<div>Opens the datepicker in a dialog box.</div>
<ul>
<li>
<div><strong>date</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Date">Date</a>
</div>
<div>The initial date.</div>
</li>
<li>
<div><strong>onSelect</strong></div>
<div>Type: <a href="http://api.jquery.com/Types/#Function">Function</a>()</div>
<div>A callback function when a date is selected. The function receives the date text and date picker instance as parameters.</div>
</li>
<li>
<div><strong>settings</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Options">Options</a>
</div>
<div>The new settings for the date picker.</div>
</li>
<li>
<div><strong>pos</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number%5B2%5D%20or%20MouseEvent">Number[2] or MouseEvent</a>
</div>
<div>The position of the top/left of the dialog as <code>[x, y]</code> or a <code>MouseEvent</code> that contains the coordinates. If not specified the dialog is centered on the screen.</div>
</li>
</ul>
</div></div>
<div id="method-getDate"><div class="api-item">
<h3>getDate() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Date">Date</a></span>
</h3>
<div>Returns the current date for the datepicker or <code>null</code> if no date has been selected.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-hide"><div class="api-item">
<h3>hide()</h3>
<div>Close a previously opened date picker.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-isDisabled"><div class="api-item">
<h3>isDisabled() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Boolean">Boolean</a></span>
</h3>
<div>Determine whether a date picker has been disabled.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current datepicker options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the datepicker option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the datepicker.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-refresh"><div class="api-item">
<h3>refresh()</h3>
<div>Redraw the date picker, after having made some external modifications.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-setDate"><div class="api-item">
<h3>setDate( date )</h3>
<div>Sets the date for the datepicker. The new date may be a <code>Date</code> object or a string in the current <a href="#option-dateFormat">date format</a> (e.g., <code>"01/26/2009"</code>), a number of days from today (e.g., <code>+7</code>) or a string of values and periods (<code>"y"</code> for years, <code>"m"</code> for months, <code>"w"</code> for weeks, <code>"d"</code> for days, e.g., <code>"+1m +7d"</code>), or <code>null</code> to clear the selected date.</div>
<ul><li>
<div><strong>date</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Date">Date</a>
</div>
<div>The new date.</div>
</li></ul>
</div></div>
<div id="method-show"><div class="api-item">
<h3>show()</h3>
<div>Open the date picker. If the datepicker is attached to an input, the input must be visible for the datepicker to be shown.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the datepicker.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><div class="longdesc" id="entry-longdesc">
<p>The jQuery UI Datepicker is a highly configurable plugin that adds datepicker functionality to your pages. You can customize the date format and language, restrict the selectable date ranges and add in buttons and other navigation options easily.</p>
<p>By default, the datepicker calendar opens in a small overlay when the associated text field gains focus. For an inline calendar, simply attach the datepicker to a div or span.</p>
<h3>Keyboard interaction</h3>
<p>While the datepicker is open, the following key commands are available:</p>
<ul>
<li>PAGE UP: Move to the previous month.</li>
<li>PAGE DOWN: Move to the next month.</li>
<li>CTRL+PAGE UP: Move to the previous year.</li>
<li>CTRL+PAGE DOWN: Move to the next year.</li>
<li>CTRL+HOME: Move to the current month. Open the datepicker if closed.</li>
<li>CTRL+LEFT: Move to the previous day.</li>
<li>CTRL+RIGHT: Move to the next day.</li>
<li>CTRL+UP: Move to the previous week.</li>
<li>CTRL+DOWN: Move the next week.</li>
<li>ENTER: Select the focused date.</li>
<li>CTRL+END: Close the datepicker and erase the date.</li>
<li>ESCAPE: Close the datepicker without selection.</li>
</ul>
<h3 id="utility-functions">Utility functions</h3>
<ul>
<li>$.datepicker.setDefaults( settings ) - Set settings for all datepicker instances.</li>
<li>$.datepicker.formatDate( format, date, settings ) - Format a date into a string value with a specified format.</li>
<li>$.datepicker.parseDate( format, value, settings ) - Extract a date from a string value with a specified format.</li>
<li>$.datepicker.iso8601Week( date ) - Determine the week of the year for a given date: 1 to 53.</li>
<li>$.datepicker.noWeekends - Set as beforeShowDay function to prevent selection of weekends.</li>
</ul>
<h3>Localization</h3>
<p>Datepicker provides support for localizing its content to cater for different languages and date formats. Each localization is contained within its own file with the language code appended to the name, e.g., <code>jquery.ui.datepicker-fr.js</code> for French. The desired localization file should be included after the main datepicker code. Each localization file adds its settings to the set of available localizations and automatically applies them as defaults for all instances.</p>
<p>The <code>$.datepicker.regional</code> attribute holds an array of localizations, indexed by language code, with <code>""</code> referring to the default (English). Each entry is an object with the following attributes: <code>closeText</code>, <code>prevText</code>, <code>nextText</code>, <code>currentText</code>, <code>monthNames</code>, <code>monthNamesShort</code>, <code>dayNames</code>, <code>dayNamesShort</code>, <code>dayNamesMin</code>, <code>weekHeader</code>, <code>dateFormat</code>, <code>firstDay</code>, <code>isRTL</code>, <code>showMonthAfterYear</code>, and <code>yearSuffix</code>.</p>
<p>You can restore the default localizations with:</p>
<code>$.datepicker.setDefaults( $.datepicker.regional[ "" ] );</code>
<p>And can then override an individual datepicker for a specific locale:</p>
<code>$( selector ).datepicker( $.datepicker.regional[ "fr" ] );</code>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Datepicker.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>datepicker demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"datepicker"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number13 index12 alt2"> </div><div class="line number14 index13 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="plain">$( "#datepicker" ).datepicker();</code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number17 index16 alt2"> </div><div class="line number18 index17 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number19 index18 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="300"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/datepicker.html | HTML | bsd | 125,772 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI resizable documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Resizable Widget",
"excerpt":
"Change the size of an element using the mouse.",
"termSlugs": {
"category": [
"interactions"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-alsoResize">alsoResize</a></div>
<div><a href="#option-animate">animate</a></div>
<div><a href="#option-animateDuration">animateDuration</a></div>
<div><a href="#option-animateEasing">animateEasing</a></div>
<div><a href="#option-aspectRatio">aspectRatio</a></div>
<div><a href="#option-autoHide">autoHide</a></div>
<div><a href="#option-cancel">cancel</a></div>
<div><a href="#option-containment">containment</a></div>
<div><a href="#option-delay">delay</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-distance">distance</a></div>
<div><a href="#option-ghost">ghost</a></div>
<div><a href="#option-grid">grid</a></div>
<div><a href="#option-handles">handles</a></div>
<div><a href="#option-helper">helper</a></div>
<div><a href="#option-maxHeight">maxHeight</a></div>
<div><a href="#option-maxWidth">maxWidth</a></div>
<div><a href="#option-minHeight">minHeight</a></div>
<div><a href="#option-minWidth">minWidth</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
<div><a href="#event-start">start</a></div>
<div><a href="#event-resize">resize</a></div>
<div><a href="#event-stop">stop</a></div>
</div></section><article id="resizable1" class="entry widget"><h2 class="section-title">
<span>Resizable Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Change the size of an element using the mouse.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-alsoResize" class="api-item first-item">
<h3>alsoResize<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#jQuery">jQuery</a> or <a href="http://api.jquery.com/Types#Element">Element</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>One or more elements to resize synchronously with the resizable element.</div>
</div>
<div id="option-animate" class="api-item">
<h3>animate<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Animates to the final size after resizing.</div>
</div>
<div id="option-animateDuration" class="api-item">
<h3>animateDuration<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"slow"</code>
</div>
<div>How long to animate when using the <a href="#option-animate"><code>animate</code></a> option.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>: Duration in milliseconds.</li>
<li>
<strong>String</strong>: A named duration, such as <code>"slow"</code> or <code>"fast"</code>.</li>
</ul>
</div>
<div id="option-animateEasing" class="api-item">
<h3>animateEasing<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"swing"</code>
</div>
<div>Which <a href="/easings/">easing</a> to apply when using the <a href="#option-animate"><code>animate</code></a> option.</div>
</div>
<div id="option-aspectRatio" class="api-item">
<h3>aspectRatio<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the element should be constrained to a specific aspect ratio.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: When set to <code>true</code>, the element will maintain its original aspect ratio.</li>
<li>
<strong>Number</strong>: Force the element to maintain a specific aspect ratio during resizing.</li>
</ul>
</div>
<div id="option-autoHide" class="api-item">
<h3>autoHide<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the handles should hide when the user is not hovering over the element.</div>
</div>
<div id="option-cancel" class="api-item">
<h3>cancel<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"input,textarea,button,select,option"</code>
</div>
<div>Prevents resizing from starting on specified elements.</div>
</div>
<div id="option-containment" class="api-item">
<h3>containment<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#Element">Element</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Constrains resizing to within the bounds of the specified element or region.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Selector</strong>: The resizable element will be contained to the bounding box of the first element found by the selector. If no element is found, no containment will be set.</li>
<li>
<strong>Element</strong>: The resizable element will be contained to the bounding box of this element.</li>
<li>
<strong>String</strong>: Possible values: <code>"parent"</code> and <code>"document"</code>.</li>
</ul>
</div>
<div id="option-delay" class="api-item">
<h3>delay<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>Tolerance, in milliseconds, for when resizing should start. If specified, resizing will not start until after mouse is moved beyond duration. This can help prevent unintended resizing when clicking on an element.</div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the resizable if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the resizable with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).resizable({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).resizable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).resizable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-distance" class="api-item">
<h3>distance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1</code>
</div>
<div>Tolerance, in pixels, for when resizing should start. If specified, resizing will not start until after mouse is moved beyond distance. This can help prevent unintended resizing when clicking on an element.</div>
</div>
<div id="option-ghost" class="api-item">
<h3>ghost<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If set to <code>true</code>, a semi-transparent helper element is shown for resizing.</div>
</div>
<div id="option-grid" class="api-item">
<h3>grid<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Snaps the resizing element to a grid, every x and y pixels. Array values: <code>[ x, y ]</code>.</div>
</div>
<div id="option-handles" class="api-item">
<h3>handles<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"e, s, se"</code>
</div>
<div>Which handles can be used for resizing.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>String</strong>: A comma delimited list of any of the following: n, e, s, w, ne, se, sw, nw, all. The necessary handles will be auto-generated by the plugin.</li>
<li>
<strong>Object</strong>: The following keys are supported: { n, e, s, w, ne, se, sw, nw }. The value of any specified should be a jQuery selector matching the child element of the resizable to use as that handle. If the handle is not a child of the resizable, you can pass in the DOMElement or a valid jQuery object directly.</li>
</ul>
</div>
<div id="option-helper" class="api-item">
<h3>helper<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>A class name that will be added to a proxy element to outline the resize during the drag of the resize handle. Once the resize is complete, the original element is sized.</div>
</div>
<div id="option-maxHeight" class="api-item">
<h3>maxHeight<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>The maximum height the resizable should be allowed to resize to.</div>
</div>
<div id="option-maxWidth" class="api-item">
<h3>maxWidth<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>The maximum width the resizable should be allowed to resize to.</div>
</div>
<div id="option-minHeight" class="api-item">
<h3>minHeight<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>10</code>
</div>
<div>The minimum height the resizable should be allowed to resize to.</div>
</div>
<div id="option-minWidth" class="api-item">
<h3>minWidth<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>10</code>
</div>
<div>The minimum width the resizable should be allowed to resize to.</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the resizable functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the resizable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the resizable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current resizable options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the resizable option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the resizable.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the resizable element.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-create" class="api-item first-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the resizable is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-resize" class="api-item">
<h3>resize( event, ui )</h3>
<div>This event is triggered during the resize, on the drag of the resize handler.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the element to be resized</div>
</li>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper that's being resized</div>
</li>
<li>
<div><strong>originalElement</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the original element before it is wrapped</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The position represented as <code>{ left, top }</code> before the resizable is resized</div>
</li>
<li>
<div><strong>originalSize</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The size represented as <code>{ width, height }</code> before the resizable is resized</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position represented as <code>{ left, top }</code>
</div>
</li>
<li>
<div><strong>size</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current size represented as <code>{ width, height }</code>
</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-start" class="api-item">
<h3>start( event, ui )</h3>
<div>This event is triggered at the start of a resize operation.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the element to be resized</div>
</li>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper that's being resized</div>
</li>
<li>
<div><strong>originalElement</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the original element before it is wrapped</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The position represented as <code>{ left, top }</code> before the resizable is resized</div>
</li>
<li>
<div><strong>originalSize</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The size represented as <code>{ width, height }</code> before the resizable is resized</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position represented as <code>{ left, top }</code>
</div>
</li>
<li>
<div><strong>size</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current size represented as <code>{ width, height }</code>
</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-stop" class="api-item">
<h3>stop( event, ui )</h3>
<div>This event is triggered at the end of a resize operation.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the element to be resized</div>
</li>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper that's being resized</div>
</li>
<li>
<div><strong>originalElement</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the original element before it is wrapped</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The position represented as <code>{ left, top }</code> before the resizable is resized</div>
</li>
<li>
<div><strong>originalSize</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The size represented as <code>{ width, height }</code> before the resizable is resized</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position represented as <code>{ left, top }</code>
</div>
</li>
<li>
<div><strong>size</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current size represented as <code>{ width, height }</code>
</div>
</li>
</ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>The jQuery UI Resizable plugin makes selected elements resizable (meaning they have draggable resize handles). You can specify one or more handles as well as min and max width and height.</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Resizable.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>resizable demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#resizable {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="plain">} </</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number17 index16 alt2"> </div><div class="line number18 index17 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"resizable"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number19 index18 alt2"> </div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number21 index20 alt2"><code class="plain">$( "#resizable" ).resizable();</code></div><div class="line number22 index21 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"> </div><div class="line number24 index23 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number25 index24 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/resizable.html | HTML | bsd | 29,001 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI dialog documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Dialog Widget",
"excerpt":
"Open content in an interactive overlay.",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-autoOpen">autoOpen</a></div>
<div><a href="#option-buttons">buttons</a></div>
<div><a href="#option-closeOnEscape">closeOnEscape</a></div>
<div><a href="#option-closeText">closeText</a></div>
<div><a href="#option-dialogClass">dialogClass</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-draggable">draggable</a></div>
<div><a href="#option-height">height</a></div>
<div><a href="#option-hide">hide</a></div>
<div><a href="#option-maxHeight">maxHeight</a></div>
<div><a href="#option-maxWidth">maxWidth</a></div>
<div><a href="#option-minHeight">minHeight</a></div>
<div><a href="#option-minWidth">minWidth</a></div>
<div><a href="#option-modal">modal</a></div>
<div><a href="#option-position">position</a></div>
<div><a href="#option-resizable">resizable</a></div>
<div><a href="#option-show">show</a></div>
<div><a href="#option-stack">stack</a></div>
<div><a href="#option-title">title</a></div>
<div><a href="#option-width">width</a></div>
<div><a href="#option-zIndex">zIndex</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-close">close</a></div>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-isOpen">isOpen</a></div>
<div><a href="#method-moveToTop">moveToTop</a></div>
<div><a href="#method-open">open</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-beforeClose">beforeClose</a></div>
<div><a href="#event-create">create</a></div>
<div><a href="#event-open">open</a></div>
<div><a href="#event-focus">focus</a></div>
<div><a href="#event-dragStart">dragStart</a></div>
<div><a href="#event-drag">drag</a></div>
<div><a href="#event-dragStop">dragStop</a></div>
<div><a href="#event-resizeStart">resizeStart</a></div>
<div><a href="#event-resize">resize</a></div>
<div><a href="#event-resizeStop">resizeStop</a></div>
<div><a href="#event-close">close</a></div>
</div></section><article id="dialog1" class="entry widget"><h2 class="section-title">
<span>Dialog Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Open content in an interactive overlay.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-autoOpen" class="api-item first-item">
<h3>autoOpen<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>If set to <code>true</code>, the dialog will automatically open upon initialization. If <code>false</code>, the dialog will stay hidden until the <a href="#method-open"><code>open()</code></a> method is called.</div>
</div>
<div id="option-buttons" class="api-item">
<h3>buttons<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a> or <a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{}</code>
</div>
<div>Specifies which buttons should be displayed on the dialog. The context of the callback is the dialog element; if you need access to the button, it is available as the target of the event object.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Object</strong>: The keys are the button labels and the values are the callbacks for when the associated button is clicked.</li>
<li>
<strong>Array</strong>: Each element of the array must be an object defining the attributes, properties, and event handlers to set on the button.</li>
</ul>
</div>
<div id="option-closeOnEscape" class="api-item">
<h3>closeOnEscape<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>Specifies whether the dialog should close when it has focus and the user presses the esacpe (ESC) key.</div>
</div>
<div id="option-closeText" class="api-item">
<h3>closeText<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"close"</code>
</div>
<div>Specifies the text for the close button. Note that the close text is visibly hidden when using a standard theme.</div>
</div>
<div id="option-dialogClass" class="api-item">
<h3>dialogClass<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>""</code>
</div>
<div>The specified class name(s) will be added to the dialog, for additional theming.</div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the dialog if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the dialog with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).dialog({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).dialog( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).dialog( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-draggable" class="api-item">
<h3>draggable<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>If set to <code>true</code>, the dialog will be draggable by the title bar. Requires the <a href="/draggable/">jQuery UI Draggable wiget</a> to be included.</div>
</div>
<div id="option-height" class="api-item">
<h3>height<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"auto"</code>
</div>
<div>The height of the dialog.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>: The height in pixels.</li>
<li>
<strong>String</strong>: The only supported string value is <code>"auto"</code> which will allow the dialog height to adjust based on its content.</li>
</ul>
</div>
<div id="option-hide" class="api-item">
<h3>hide<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>If and how to animate the hiding of the dialog.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>:
The dialog will fade out while animating the height and width for the specified duration.
</li>
<li>
<strong>String</strong>:
The dialog will be hidden using the specified jQuery UI effect. See the <a href="/category/effects/">list of effects</a> for possible values.
</li>
<li>
<strong>Object</strong>: If the value is an object, then <code>effect</code>, <code>duration</code>, and <code>easing</code> properties may be provided. The <code>effect</code> property must be the name of a jQuery UI effect. When using a jQuery UI effect that supports additional settings, you may include those settings in the object and they will be passed to the effect. If <code>duration</code> or <code>easing</code> is omitted, then the default values will be used.</li>
</ul>
</div>
<div id="option-maxHeight" class="api-item">
<h3>maxHeight<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>The maximum height to which the dialog can be resized, in pixels.</div>
</div>
<div id="option-maxWidth" class="api-item">
<h3>maxWidth<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>The maximum width to which the dialog can be resized, in pixels.</div>
</div>
<div id="option-minHeight" class="api-item">
<h3>minHeight<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>150</code>
</div>
<div>The minimum height to which the dialog can be resized, in pixels.</div>
</div>
<div id="option-minWidth" class="api-item">
<h3>minWidth<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>150</code>
</div>
<div>The minimum width to which the dialog can be resized, in pixels.</div>
</div>
<div id="option-modal" class="api-item">
<h3>modal<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If set to <code>true</code>, the dialog will have modal behavior; other items on the page will be disabled, i.e., cannot be interacted with. Modal dialogs create an overlay below the dialog but above other page elements.</div>
</div>
<div id="option-position" class="api-item">
<h3>position<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{ my: "center", at: "center", of: window }</code>
</div>
<div>Specifies where the dialog should be displayed. The dialog will handle collisions such that as much of the dialog is visible as possible.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Object</strong>: Identifies the position of the dialog when opened. The <code>of</code> option defaults to the window, but you can specify another element to position against. You can refer to the <a href="/position">jQuery UI Position</a> utility for more details about the various options.</li>
<li>
<strong>String</strong>: A string representing the position within the viewport. Possible values: <code>"center"</code>, <code>"left"</code>, <code>"right"</code>, <code>"top"</code>, <code>"bottom"</code>.</li>
<li>
<strong>Array</strong>: An array containing an <em>x, y</em> coordinate pair in pixel offset from the top left corner of the viewport or the name of a possible string value.</li>
</ul>
</div>
<div id="option-resizable" class="api-item">
<h3>resizable<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>If set to <code>true</code>, the dialog will be resizable. Requires the <a href="/resizable/">jQuery UI Resizable widget</a> to be included.</div>
</div>
<div id="option-show" class="api-item">
<h3>show<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>If and how to animate the showing of the dialog.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>:
The dialog will fade in while animating the height and width for the specified duration.
</li>
<li>
<strong>String</strong>:
The dialog will be shown using the specified jQuery UI effect. See the <a href="/category/effects/">list of effects</a> for possible values.
</li>
<li>
<strong>Object</strong>: If the value is an object, then <code>effect</code>, <code>duration</code>, and <code>easing</code> properties may be provided. The <code>effect</code> property must be the name of a jQuery UI effect. When using a jQuery UI effect that supports additional settings, you may include those settings in the object and they will be passed to the effect. If <code>duration</code> or <code>easing</code> is omitted, then the default values will be used.</li>
</ul>
</div>
<div id="option-stack" class="api-item">
<h3>stack<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>Specifies whether the dialog will stack on top of other dialogs. This will cause the dialog to move to the front of other dialogs when it gains focus.</div>
</div>
<div id="option-title" class="api-item">
<h3>title<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>""</code>
</div>
<div>Specifies the title of the dialog. Any valid HTML may be set as the title. The title can also be specified by the <code>title</code> attribute on the dialog source element.</div>
</div>
<div id="option-width" class="api-item">
<h3>width<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>300</code>
</div>
<div>The width of the dialog, in pixels.</div>
</div>
<div id="option-zIndex" class="api-item">
<h3>zIndex<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1000</code>
</div>
<div>The starting z-index for the dialog.</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-close"><div class="api-item first-item">
<h3>close()</h3>
<div>Closes the dialog.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-destroy"><div class="api-item">
<h3>destroy()</h3>
<div>
Removes the dialog functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the dialog.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the dialog.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-isOpen"><div class="api-item">
<h3>isOpen() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Boolean">Boolean</a></span>
</h3>
<div>Whether the dialog is currently open.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-moveToTop"><div class="api-item">
<h3>moveToTop()</h3>
<div>Moves the dialog to the top of the dialog stack.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-open"><div class="api-item">
<h3>open()</h3>
<div>Opens the dialog.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current dialog options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the dialog option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the dialog.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the generated wrapper.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-beforeClose" class="api-item first-item">
<h3>beforeClose( event, ui )</h3>
<div>Triggered when a dialog is about to close. If canceled, the dialog will not close.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-close" class="api-item">
<h3>close( event, ui )</h3>
<div>Triggered when the dialog is closed.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the dialog is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-drag" class="api-item">
<h3>drag( event, ui )</h3>
<div>Triggered while the dialog is being dragged.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current CSS position of the dialog.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current offset position of the dialog.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-dragStart" class="api-item">
<h3>dragStart( event, ui )</h3>
<div>Triggered when the user starts dragging the dialog.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current CSS position of the dialog.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current offset position of the dialog.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-dragStop" class="api-item">
<h3>dragStop( event, ui )</h3>
<div>Triggered after the dialog has been dragged.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current CSS position of the dialog.</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current offset position of the dialog.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-focus" class="api-item">
<h3>focus( event, ui )</h3>
<div>Triggered when the dialog gains focus.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-open" class="api-item">
<h3>open( event, ui )</h3>
<div>Triggered when the dialog is opened.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-resize" class="api-item">
<h3>resize( event, ui )</h3>
<div>Triggered while the dialog is being resized.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>orginalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The CSS position of the dialog prior to being resized.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current CSS position of the dialog.</div>
</li>
<li>
<div><strong>originalSize</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The size of the dialog prior to being resized.</div>
</li>
<li>
<div><strong>size</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current size of the dialog.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-resizeStart" class="api-item">
<h3>resizeStart( event, ui )</h3>
<div>Triggered when the user starts resizing the dialog.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>orginalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The CSS position of the dialog prior to being resized.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current CSS position of the dialog.</div>
</li>
<li>
<div><strong>originalSize</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The size of the dialog prior to being resized.</div>
</li>
<li>
<div><strong>size</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current size of the dialog.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-resizeStop" class="api-item">
<h3>resizeStop( event, ui )</h3>
<div>Triggered after the dialog has been resized.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>orginalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The CSS position of the dialog prior to being resized.</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current CSS position of the dialog.</div>
</li>
<li>
<div><strong>originalSize</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The size of the dialog prior to being resized.</div>
</li>
<li>
<div><strong>size</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current size of the dialog.</div>
</li>
</ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>A dialog is a floating window that contains a title bar and a content area. The dialog window can be moved, resized and closed with the 'x' icon by default.</p>
<p>If the content length exceeds the maximum height, a scrollbar will automatically appear.</p>
<p>A bottom button bar and semi-transparent modal overlay layer are common options that can be added.</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Dialog</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>dialog demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">button</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"opener"</code><code class="plain">>open the dialog</</code><code class="keyword">button</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"dialog"</code> <code class="color1">title</code><code class="plain">=</code><code class="string">"Dialog Title"</code><code class="plain">>I'm a dialog</</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number14 index13 alt1"> </div><div class="line number15 index14 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain">$( "#dialog" ).dialog({ autoOpen: false });</code></div><div class="line number17 index16 alt2"><code class="plain">$( "#opener" ).click(function() {</code></div><div class="line number18 index17 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#dialog" ).dialog( "open" );</code></div><div class="line number19 index18 alt2"><code class="plain">});</code></div><div class="line number20 index19 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/dialog.html | HTML | bsd | 34,635 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI drop-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Drop Effect",
"excerpt":
"\n\t\tThe drop effect hides or shows an element fading in/out and sliding in a direction.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="drop1" class="entry effect"><h2 class="section-title"><span>Drop Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The drop effect hides or shows an element fading in/out and sliding in a direction.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">drop</h4>
<ul><li>
<div>
<strong>direction</strong> (default: <code>"left"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>
<p>The direction the element will fall to hide the element, or the direction from which the element will be revealed.</p>
<p>Possible Values: <code>up</code>, <code>down</code>, <code>left</code>, <code>right</code>.</p>
</div>
</li></ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the drop effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>drop demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "drop" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/drop-effect.html | HTML | bsd | 8,738 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI spinner documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Spinner Widget",
"excerpt":
"\n\t\tEnhance a text input for entering numeric values, with up/down buttons and arrow key handling.\n\t",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-culture">culture</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-icons">icons</a></div>
<div><a href="#option-incremental">incremental</a></div>
<div><a href="#option-max">max</a></div>
<div><a href="#option-min">min</a></div>
<div><a href="#option-numberFormat">numberFormat</a></div>
<div><a href="#option-page">page</a></div>
<div><a href="#option-step">step</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-pageDown">pageDown</a></div>
<div><a href="#method-pageUp">pageUp</a></div>
<div><a href="#method-stepDown">stepDown</a></div>
<div><a href="#method-stepUp">stepUp</a></div>
<div><a href="#method-value">value</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
<div><a href="#event-start">start</a></div>
<div><a href="#event-spin">spin</a></div>
<div><a href="#event-stop">stop</a></div>
<div><a href="#event-change">change</a></div>
</div></section><article id="spinner1" class="entry widget"><h2 class="section-title">
<span>Spinner Widget</span><span class="version-details">version added: 1.9</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
Enhance a text input for entering numeric values, with up/down buttons and arrow key handling.
</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-culture" class="api-item first-item">
<h3>culture<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>Sets the culture to use for parsing and formatting the value. If <code>null</code>, the currently set culture in <code>Globalize</code> is used, see <a href="https://github.com/jquery/globalize">Globalize docs</a> for available cultures. Only relevant if the <a href="#option-numberFormat"><code>numberFormat</code></a> option is set. Requires <a href="https://github.com/jquery/globalize">Globalize</a> to be included.</div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the spinner if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the spinner with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).spinner({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).spinner( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).spinner( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-icons" class="api-item">
<h3>icons<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{ down: "ui-icon-triangle-1-s", up: "ui-icon-triangle-1-n" }</code>
</div>
<div>
Icons to use for buttons, matching an icon defined by the jQuery UI CSS Framework.
<ul>
<li>up (string, default: "ui-icon-triangle-1-n")</li>
<li>down (string, default: "ui-icon-triangle-1-s")</li>
</ul>
</div>
</div>
<div id="option-incremental" class="api-item">
<h3>incremental<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types/#Function">Function</a>()</span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>Controls the number of steps taken when holding down a spin button.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: When set to <code>true</code>, the stepping delta will increase when spun incessantly. When set to <code>false</code>, all steps are equal (as defined by the <a href="#option-step"><code>step</code></a> option).</li>
<li>
<strong>Function</strong>: Receives one parameter: the number of spins that have occurred. Must return the number of steps that should occur for the current spin.</li>
</ul>
</div>
<div id="option-max" class="api-item">
<h3>max<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>The maximum allowed value. The element's <code>max</code> attribute is used if it exists and the option is not explicitly set. If <code>null</code>, there is no maximum enforced.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>: The maximum value.</li>
<li>
<strong>String</strong>: If <a href="https://github.com/jquery/globalize">Globalize</a> is included, the <code>max</code> option can be passed as a string which will be parsed based on the <a href="#opiton-numberFormat"><code>numberFormat</code></a> and <a href="#option-culture"><code>culture</code></a> options; otherwise it will fall back to the native <code>parseFloat()</code> method.</li>
</ul>
</div>
<div id="option-min" class="api-item">
<h3>min<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>The minimum allowed value. The element's <code>min</code> attribute is used if it exists and the option is not explicitly set. If <code>null</code>, there is no minimum enforced.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>: The minimum value.</li>
<li>
<strong>String</strong>: If <a href="https://github.com/jquery/globalize">Globalize</a> is included, the <code>min</code> option can be passed as a string which will be parsed based on the <a href="#opiton-numberFormat"><code>numberFormat</code></a> and <a href="#option-culture"><code>culture</code></a> options; otherwise it will fall back to the native <code>parseFloat()</code> method.</li>
</ul>
</div>
<div id="option-numberFormat" class="api-item">
<h3>numberFormat<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>Format of numbers passed to <a href="https://github.com/jquery/globalize"><code>Globalize</code></a>, if available. Most common are <code>"n"</code> for a decimal number and <code>"C"</code> for a currency value. Also see the <a href="#option-culture"><code>culture</code></a> option.</div>
</div>
<div id="option-page" class="api-item">
<h3>page<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>The number of steps to take when paging via the <a href="#method-pageUp"><code>pageUp</code></a>/<a href="#method-pageDown"><code>pageDown</code></a> methods.</div>
</div>
<div id="option-step" class="api-item">
<h3>step<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>The size of the step to take when spinning via buttons or via the <a href="#method-stepUp"><code>stepUp()</code></a>/<a href="#method-stepDown"><code>stepDown()</code></a> methods. The element's <code>step</code> attribute is used if it exists and the option is not explicitly set.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Number</strong>: The size of the step.</li>
<li>
<strong>String</strong>: If <a href="https://github.com/jquery/globalize">Globalize</a> is included, the <code>step</code> option can be passed as a string which will be parsed based on the <a href="#opiton-numberFormat"><code>numberFormat</code></a> and <a href="#option-culture"><code>culture</code></a> options, otherwise it will fall back to the native <code>parseFloat</code>.</li>
</ul>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the spinner functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the spinner.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the spinner.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current spinner options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the spinner option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the spinner.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-pageDown"><div class="api-item">
<h3>pageDown( [pages ] )</h3>
<div>
Decrements the value by the specified number of pages, as defined by the <a href="#option-page"><code>page</code></a> option. Without the parameter, a single page is decremented.
</div>
<ul><li>
<div><strong>pages</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>Number of pages to decrement, defaults to 1.</div>
</li></ul>
</div></div>
<div id="method-pageUp"><div class="api-item">
<h3>pageUp( [pages ] )</h3>
<div>
Increments the value by the specified number of pages, as defined by the <a href="#option-page"><code>page</code></a> option. Without the parameter, a single page is incremented.
</div>
<ul><li>
<div><strong>pages</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>Number of pages to increment, defaults to 1.</div>
</li></ul>
</div></div>
<div id="method-stepDown"><div class="api-item">
<h3>stepDown( [steps ] )</h3>
<div>
Decrements the value by the specified number of steps. Without the parameter, a single step is decremented.
<p>If the resulting value is above the max, below the min, or reuslts in a step mismatch, the value will be adjusted to the closest valid value.</p>
</div>
<ul><li>
<div><strong>steps</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>Number of steps to decrement, defaults to 1.</div>
</li></ul>
</div></div>
<div id="method-stepUp"><div class="api-item">
<h3>stepUp( [steps ] )</h3>
<div>
Increments the value by the specified number of steps. Without the parameter, a single step is incremented.
<p>If the resulting value is above the max, below the min, or reuslts in a step mismatch, the value will be adjusted to the closest valid value.</p>
</div>
<ul><li>
<div><strong>steps</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>Number of steps to increment, defaults to 1.</div>
</li></ul>
</div></div>
<div id="method-value">
<div class="api-item">
<h3>value() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Number">Number</a></span>
</h3>
<div>Gets the current value as a number. The value is parsed based on the <a href="#option-numberFormat"><code>numberFormat</code></a> and <a href="#option-culture"><code>culture</code></a> options.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>value( value )</h3>
<div></div>
<ul><li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The value to set. If passed as a string, the value is parsed based on the <a href="#option-numberFormat"><code>numberFormat</code></a> and <a href="#option-culture"><code>culture</code></a> options.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the generated wrapper.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-change" class="api-item first-item">
<h3>change( event, ui )</h3>
<div>
Triggered when the value of the spinner has changed and the input is no longer focused.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the spinner is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-spin" class="api-item">
<h3>spin( event, ui )</h3>
<div>
Triggered during increment/decrement (to determine direction of spin compare current value with <code>ui.value</code>).
<p>Can be canceled, preventing the value from being updated.</p>
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The new value to be set, unless the event is cancelled.</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-start" class="api-item">
<h3>start( event, ui )</h3>
<div>
Triggered before a spin. Can be canceled, preventing the spin from occurring.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-stop" class="api-item">
<h3>stop( event, ui )</h3>
<div>Triggered after a spin.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>Spinner wraps a text input, adds two buttons to increment and decrement the current value, along with handling key events for the same purpose. It delegates to <a href="https://github.com/jquery/globalize">Globalize</a> for number formatting and parsing.</p>
<h3>Keyboard interaction</h3>
<ul>
<li>UP: Increment the value by one step.</li>
<li>DOWN: Decrement the value by one step.</li>
<li>PAGE UP: Increment the value by one page.</li>
<li>PAGE DOWN: Decrement the value by one page.</li>
</ul>
<p>Focus stays in the text field, even after using the mouse to click one of the spin buttons.</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Plain number spinner</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>spinner demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">input</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"spinner"</code><code class="plain">></code></div><div class="line number13 index12 alt2"> </div><div class="line number14 index13 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="plain">$( "#spinner" ).spinner();</code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number17 index16 alt2"> </div><div class="line number18 index17 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number19 index18 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="50"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/spinner.html | HTML | bsd | 24,990 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI slide-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Slide Effect",
"excerpt":
"Slides the element out of the viewport.",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="slide1" class="entry effect"><h2 class="section-title"><span>Slide Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Slides the element out of the viewport.</p>
<ul class="signatures"><li class="signature">
<h4 class="name">slide</h4>
<ul>
<li>
<div>
<strong>direction</strong> (default: <code>"both"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The direction of the effect. Possible values: <code>"left"</code>, <code>"right"</code>, <code>"up"</code>, <code>"down"</code>.</div>
</li>
<li>
<div>
<strong>distance</strong> (default: <code>element's outerWidth</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The distance of the effect. Defaults to either the height or width of the elemenet depending on the <code>direction</code> argument. Can be set to any integer less than the width/height of the element.</div>
</li>
</ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the slide effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>slide demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "slide" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/slide-effect.html | HTML | bsd | 8,921 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI accordion documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Accordion Widget",
"excerpt":
"Convert a pair of headers and content panels into an accordion.",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-active">active</a></div>
<div><a href="#option-animate">animate</a></div>
<div><a href="#option-collapsible">collapsible</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-event">event</a></div>
<div><a href="#option-header">header</a></div>
<div><a href="#option-heightStyle">heightStyle</a></div>
<div><a href="#option-icons">icons</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-refresh">refresh</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-activate">activate</a></div>
<div><a href="#event-beforeActivate">beforeActivate</a></div>
<div><a href="#event-create">create</a></div>
</div></section><article id="accordion1" class="entry widget"><h2 class="section-title">
<span>Accordion Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Convert a pair of headers and content panels into an accordion.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-active" class="api-item first-item">
<h3>active<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>
Which panel is currently open.
</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: Setting <code>active</code> to <code>false</code> will collapse all panels. This requires the <a href="#option-collapsible"><code>collapsible</code></a> option to be <code>true</code>.</li>
<li>
<strong>Integer</strong>: The zero-based index of the panel that is active (open). A negative value selects panels going backward from the last panel.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the accordion with the active option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion({ active: 2 });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the active option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">active = $( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"active"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"active"</code><code class="plain">, 2 );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-animate" class="api-item">
<h3>animate<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{}</code>
</div>
<div>If and how to animate changing panels.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: A value of <code>false</code> will disable animations.</li>
<li>
<strong>Number</strong>: Duration in milliseconds with default easing.</li>
<li>
<strong>String</strong>: Name of <a href="/easings/">easing</a> to use with default duration.</li>
<li>
<strong>Object</strong>: Animation settings with <code>easing</code> and <code>duration</code> properties.
<ul>
<li>Can also contain a <code>down</code> property with any of the above options.</li>
<li>"Down" animations occur when the panel being activated has a lower index than the currently active panel.</li>
</ul>
</li>
</ul>
<strong>Code examples:</strong><p>Initialize the accordion with the animate option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion({ animate: </code><code class="string">"bounceslide"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the animate option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">animate = $( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"animate"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"animate"</code><code class="plain">, </code><code class="string">"bounceslide"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-collapsible" class="api-item">
<h3>collapsible<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether all the sections can be closed at once. Allows collapsing the active section.</div>
<strong>Code examples:</strong><p>Initialize the accordion with the collapsible option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion({ collapsible: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the collapsible option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">collapsible = $( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"collapsible"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"collapsible"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the accordion if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the accordion with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-event" class="api-item">
<h3>event<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"click"</code>
</div>
<div>The event that accordion headers will react to in order to activate the associated panel. Multiple events can be specificed, separated by a space.</div>
<strong>Code examples:</strong><p>Initialize the accordion with the event option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion({ event: </code><code class="string">"mouseover"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the event option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">event = $( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"event"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"event"</code><code class="plain">, </code><code class="string">"mouseover"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-header" class="api-item">
<h3>header<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"> li > :first-child,> :not(li):even"</code>
</div>
<div>
<p>Selector for the header element, applied via <code>.find()</code> on the main accordion element. Content panels must be the sibling immedately after their associated headers.</p>
</div>
<strong>Code examples:</strong><p>Initialize the accordion with the header option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion({ header: </code><code class="string">"h3"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the header option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">header = $( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"header"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"header"</code><code class="plain">, </code><code class="string">"h3"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-heightStyle" class="api-item">
<h3>heightStyle<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"auto"</code>
</div>
<div>
<p>Controls the height of the accordion and each panel. Possible values:</p>
<ul>
<li>
<code>"auto"</code>: All panels will be set to the height of the tallest panel.</li>
<li>
<code>"fill"</code>: Expand to the available height based on the accordion's parent height.</li>
<li>
<code>"content"</code>: Each panel will be only as tall as its content.</li>
</ul>
</div>
<strong>Code examples:</strong><p>Initialize the accordion with the heightStyle option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion({ heightStyle: </code><code class="string">"fill"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the heightStyle option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">heightStyle = $( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"heightStyle"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"heightStyle"</code><code class="plain">, </code><code class="string">"fill"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-icons" class="api-item">
<h3>icons<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{ "header": "ui-icon-triangle-1-e", "activeHeader": "ui-icon-triangle-1-s" }</code>
</div>
<div>
<p>Icons to use for headers, matching an icon defined by the jQuery UI CSS Framework. Set to <code>false</code> to have no icons displayed.</p>
<ul>
<li>header (string, default: "ui-icon-triangle-1-e")</li>
<li>activeHeader (string, default: "ui-icon-triangle-1-s")</li>
</ul>
</div>
<strong>Code examples:</strong><p>Initialize the accordion with the icons option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion({ icons: { </code><code class="string">"header"</code><code class="plain">: </code><code class="string">"ui-icon-plus"</code><code class="plain">, </code><code class="string">"headerSelected"</code><code class="plain">: </code><code class="string">"ui-icon-minus"</code> <code class="plain">} });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the icons option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">icons = $( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"icons"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).accordion( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"icons"</code><code class="plain">, { </code><code class="string">"header"</code><code class="plain">: </code><code class="string">"ui-icon-plus"</code><code class="plain">, </code><code class="string">"headerSelected"</code><code class="plain">: </code><code class="string">"ui-icon-minus"</code> <code class="plain">} );</code></div></div></td></tr></tbody></table></div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the accordion functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the accordion.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the accordion.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current accordion options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the accordion option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the accordion.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-refresh"><div class="api-item">
<h3>refresh()</h3>
<div>Recompute the height of the accordion panels. Results depend on the content and the <a href="#option-heightStyle"><code>heightStyle</code></a> option.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the accordion.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-activate" class="api-item first-item">
<h3>activate( event, ui )</h3>
<div>Triggered after a panel has been activated (after animation completes). If the accordion was previously collapsed, <code>ui.oldHeader</code> and <code>ui.oldPanel</code> will be empty jQuery objects. If the accordion is collapsing, <code>ui.newHeader</code> and <code>ui.newPanel</code> will be empty jQuery objects.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>newHeader</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The header that was just activated.</div>
</li>
<li>
<div><strong>oldHeader</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The header that was just deactivated.</div>
</li>
<li>
<div><strong>newPanel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel that was just activated.</div>
</li>
<li>
<div><strong>oldPanel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel that was just deactivated.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-beforeActivate" class="api-item">
<h3>beforeActivate( event, ui )</h3>
<div>Triggered directly before a panel is activated. Can be canceled to prevent the panel from activating. If the accordion is currently collapsed, <code>ui.oldHeader</code> and <code>ui.oldPanel</code> will be empty jQuery objects. If the accordion is collapsing, <code>ui.newHeader</code> and <code>ui.newPanel</code> will be empty jQuery objects.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>newHeader</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The header that is about to be activated.</div>
</li>
<li>
<div><strong>oldHeader</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The header that is about to be deactivated.</div>
</li>
<li>
<div><strong>newPanel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel that is about to be activated.</div>
</li>
<li>
<div><strong>oldPanel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The panel that is about to be deactivated.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>Triggered when the accordion is created. If the accordion is collapsed, <code>ui.header</code> and <code>ui.panel</code> will be empty jQuery objects.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>header</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The active header.</div>
</li>
<li>
<div><strong>panel</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The active panel.</div>
</li>
</ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>The markup of your accordion container needs pairs of headers and content panels:</p>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"accordion"</code><code class="plain">></code></div><div class="line number2 index1 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">h3</code><code class="plain">>First header</</code><code class="keyword">h3</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code><code class="plain">>First content panel</</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">h3</code><code class="plain">>Second header</</code><code class="keyword">h3</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code><code class="plain">>Second content panel</</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<p>Accordions support arbitrary markup, but each content panel must always be the next sibling after its associated header. See the <a href="#option-header"><code>header</code></a> option for information on how to use custom markup structures.</p>
<p>The panels can be activated programmatically by setting the <a href="#option-active"><code>active</code></a> option.</p>
<h3>Keyboard interaction</h3>
<p>When focus is on a header, the following key commands are available:</p>
<ul>
<li>UP/LEFT - Move focus to the previous header. If on first header, moves focus to last header.</li>
<li>DOWN/RIGHT - Move focus to the next header. If on last header, moves focus to first header.</li>
<li>HOME - Move focus to the first header.</li>
<li>END - Move focus to the last header.</li>
<li>SPACE/ENTER - Activate panel associated with focused header.</li>
</ul>
<p>When focus is in a panel:</p>
<ul>
<li>CTRL+UP: Move focus to associated header.</li>
</ul>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Accordion</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div><div class="line number30 index29 alt1">30</div><div class="line number31 index30 alt2">31</div><div class="line number32 index31 alt1">32</div><div class="line number33 index32 alt2">33</div><div class="line number34 index33 alt1">34</div><div class="line number35 index34 alt2">35</div><div class="line number36 index35 alt1">36</div><div class="line number37 index36 alt2">37</div><div class="line number38 index37 alt1">38</div><div class="line number39 index38 alt2">39</div><div class="line number40 index39 alt1">40</div><div class="line number41 index40 alt2">41</div><div class="line number42 index41 alt1">42</div><div class="line number43 index42 alt2">43</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>accordion demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"accordion"</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">h3</code><code class="plain">>Section 1</</code><code class="keyword">h3</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Mauris mauris ante, blandit et, ultrices a, suscipit eget.</code></div><div class="line number16 index15 alt1"><code class="undefined spaces"> </code><code class="plain">Integer ut neque. Vivamus nisi metus, molestie vel, gravida in,</code></div><div class="line number17 index16 alt2"><code class="undefined spaces"> </code><code class="plain">condimentum sit amet, nunc. Nam a nibh. Donec suscipit eros.</code></div><div class="line number18 index17 alt1"><code class="undefined spaces"> </code><code class="plain">Nam mi. Proin viverra leo ut odio.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number19 index18 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">h3</code><code class="plain">>Section 2</</code><code class="keyword">h3</code><code class="plain">></code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Sed non urna. Phasellus eu ligula. Vestibulum sit amet purus.</code></div><div class="line number23 index22 alt2"><code class="undefined spaces"> </code><code class="plain">Vivamus hendrerit, dolor aliquet laoreet, mauris turpis velit,</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">faucibus interdum tellus libero ac justo.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number25 index24 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number26 index25 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">h3</code><code class="plain">>Section 3</</code><code class="keyword">h3</code><code class="plain">></code></div><div class="line number27 index26 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number28 index27 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Nam enim risus, molestie et, porta ac, aliquam ac, risus.</code></div><div class="line number29 index28 alt2"><code class="undefined spaces"> </code><code class="plain">Quisque lobortis.Phasellus pellentesque purus in massa.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number30 index29 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number31 index30 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>List item one</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number32 index31 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>List item two</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number33 index32 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>List item three</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number34 index33 alt1"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number35 index34 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number36 index35 alt1"><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number37 index36 alt2"> </div><div class="line number38 index37 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number39 index38 alt2"><code class="plain">$( "#accordion" ).accordion();</code></div><div class="line number40 index39 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number41 index40 alt2"> </div><div class="line number42 index41 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number43 index42 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="350"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/accordion.html | HTML | bsd | 42,932 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI fade-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Fade Effect",
"excerpt":
"\n\t\tThe fade effect hides or shows an element by fading it.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="fade1" class="entry effect"><h2 class="section-title"><span>Fade Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The fade effect hides or shows an element by fading it.
</p>
<ul class="signatures"><li class="signature"><h4 class="name">fade</h4></li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the fade effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>fade demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "fade" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/fade-effect.html | HTML | bsd | 8,271 |
<script>{
"title":
"Puff Effect",
"excerpt":
"\n\t\tCreates a puff effect by scaling the element up and hiding it at the same time.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="puff1" class="entry effect"><h2 class="section-title"><span>Puff Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
Creates a puff effect by scaling the element up and hiding it at the same time.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">puff</h4>
<ul><li>
<div>
<strong>percent</strong> (default: <code>150</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The percentage to scale to.</div>
</li></ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the puff effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>puff demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "puff" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article> | 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/puff-effect.html | HTML | bsd | 8,230 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI explode-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Explode Effect",
"excerpt":
"\n\t\tThe explode effect hides or shows an element by splitting it into pieces.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="explode1" class="entry effect"><h2 class="section-title"><span>Explode Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The explode effect hides or shows an element by splitting it into pieces.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">explode</h4>
<ul><li>
<div>
<strong>pieces</strong> (default: <code>9</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Integer">Integer</a>
</div>
<div>The number of pieces to explode, should be a perfect square, any other values are rounded to the nearest square.</div>
</li></ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the explode effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>explode demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "explode" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/explode-effect.html | HTML | bsd | 8,615 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI slider documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Slider Widget",
"excerpt":
"Drag a handle to select a numeric value.",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-animate">animate</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-max">max</a></div>
<div><a href="#option-min">min</a></div>
<div><a href="#option-orientation">orientation</a></div>
<div><a href="#option-range">range</a></div>
<div><a href="#option-step">step</a></div>
<div><a href="#option-value">value</a></div>
<div><a href="#option-values">values</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-value">value</a></div>
<div><a href="#method-values">values</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
<div><a href="#event-start">start</a></div>
<div><a href="#event-slide">slide</a></div>
<div><a href="#event-change">change</a></div>
<div><a href="#event-stop">stop</a></div>
</div></section><article id="slider1" class="entry widget"><h2 class="section-title">
<span>Slider Widget</span><span class="version-details">version added: 1.5</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Drag a handle to select a numeric value.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-animate" class="api-item first-item">
<h3>animate<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether to slide the handle smoothly when the user clicks on the slider track. Also accepts any valid <a href="//api.jquery.com/animate/#duration">animation duration</a>.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: When set to <code>true</code>, the handle will animate with the default duration.</li>
<li>
<strong>String</strong>: The name of a speed, such as <code>"fast"</code> or <code>"slow"</code>.</li>
<li>
<strong>Number</strong>: The duration of the animation, in milliseconds.</li>
</ul>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the slider if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the slider with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).slider({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).slider( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).slider( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-max" class="api-item">
<h3>max<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>100</code>
</div>
<div>The maximum value of the slider.</div>
</div>
<div id="option-min" class="api-item">
<h3>min<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>The minimum value of the slider.</div>
</div>
<div id="option-orientation" class="api-item">
<h3>orientation<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"horizontal"</code>
</div>
<div>Determines whether the slider handles move horizontally (min on left, max on right) or vertically (min on bottom, max on top). Possible values: <code>"horizontal"</code>, <code>"vertical"</code>.</div>
</div>
<div id="option-range" class="api-item">
<h3>range<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the slider represents a range.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: If set to <code>true</code>, the slider will detect if you have two handles and create a stylable range element between these two.</li>
<li>
<strong>String</strong>: Either <code>"min"</code> or <code>"max"</code>. A min range goes from the slider min to one handle. A max range goes from one handle to the slider max.</li>
</ul>
</div>
<div id="option-step" class="api-item">
<h3>step<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1</code>
</div>
<div>Determines the size or amount of each interval or step the slider takes between the min and max. The full specified value range of the slider (max - min) should be evenly divisible by the step.</div>
</div>
<div id="option-value" class="api-item">
<h3>value<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>Determines the value of the slider, if there's only one handle. If there is more than one handle, determines the value of the first handle.</div>
</div>
<div id="option-values" class="api-item">
<h3>values<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>This option can be used to specify multiple handles. If the <a href="#option-range"><code>range</code></a> option is set to <code>true</code>, the length of <code>values</code> should be 2.</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-destroy"><div class="api-item first-item">
<h3>destroy()</h3>
<div>
Removes the slider functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the slider.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the slider.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current slider options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the slider option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the slider.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-value">
<div class="api-item">
<h3>value() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Number">Number</a></span>
</h3>
<div>Get the value of the slider.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>value( value )</h3>
<div>Set the value of the slider.</div>
<ul><li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The value to set.</div>
</li></ul>
</div>
</div>
<div id="method-values">
<div class="api-item">
<h3>values() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Array">Array</a></span>
</h3>
<div>Get the value for all handles.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>values( index ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Number">Number</a></span>
</h3>
<div>Get the value for the specified handle.</div>
<ul><li>
<div><strong>index</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Integer">Integer</a>
</div>
<div>The zero-based index of the handle.</div>
</li></ul>
</div>
<div class="api-item">
<h3>values( index, value )</h3>
<div>Set the value for the specified handle.</div>
<ul>
<li>
<div><strong>index</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Integer">Integer</a>
</div>
<div>The zero-based index of the handle.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The value to set.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>values( values )</h3>
<div>Set the value for all handles.</div>
<ul><li>
<div><strong>values</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Array">Array</a>
</div>
<div>The values to set.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the slider.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-change" class="api-item first-item">
<h3>change( event, ui )</h3>
<div>Triggered after the user slides a handle, if the value has changed; or if the value is changed programmatically via the <a href="#method-value"><code>value</code></a> method.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>handle</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the handle that was changed.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The current value of the slider.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the slider is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-slide" class="api-item">
<h3>slide( event, ui )</h3>
<div>Triggered on every mouse move during slide. The value provided in the event as <code>ui.value</code> represents the value that the handle will have as a result of the current movement. Canceling the event will prevent the handle from moving and the handle will continue to have its previous value.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>handle</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the handle being moved.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The value that the handle will move to if the event is not canceled.</div>
</li>
<li>
<div><strong>values</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Array">Array</a>
</div>
<div>An array of the current values of a multi-handled slider.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-start" class="api-item">
<h3>start( event, ui )</h3>
<div>Triggered when the user starts sliding.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>handle</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the handle being moved.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The current value of the slider.</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-stop" class="api-item">
<h3>stop( event, ui )</h3>
<div>Triggered after the user slides a handle.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>handle</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the handle that was moved.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The current value of the slider.</div>
</li>
</ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>The jQuery UI Slider plugin makes selected elements into sliders. There are various options such as multiple handles and ranges. The handle can be moved with the mouse or the arrow keys.</p>
<p>The slider widget will create handle elements with the class <code>ui-slider-handle</code> on initialization. You can specify custom handle elements by creating and appending the elements and adding the <code>ui-slider-handle</code> class before initialization. It will only create the number of handles needed to match the length of <a href="#option-value"><code>value</code></a>/<a href="#option-values"><code>values</code></a>. For example, if you specify <code>values: [ 1, 5, 18 ]</code> and create one custom handle, the plugin will create the other two.</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Slider.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>slider demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">>#slider { margin: 10px; } </</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number11 index10 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number12 index11 alt1"> </div><div class="line number13 index12 alt2"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"slider"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number14 index13 alt1"> </div><div class="line number15 index14 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain">$( "#slider" ).slider();</code></div><div class="line number17 index16 alt2"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="50"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/slider.html | HTML | bsd | 23,692 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI sortable documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Sortable Widget",
"excerpt":
"Reorder elements in a list or grid using the mouse.",
"termSlugs": {
"category": [
"interactions"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-appendTo">appendTo</a></div>
<div><a href="#option-axis">axis</a></div>
<div><a href="#option-cancel">cancel</a></div>
<div><a href="#option-connectWith">connectWith</a></div>
<div><a href="#option-containment">containment</a></div>
<div><a href="#option-cursor">cursor</a></div>
<div><a href="#option-cursorAt">cursorAt</a></div>
<div><a href="#option-delay">delay</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-distance">distance</a></div>
<div><a href="#option-dropOnEmpty">dropOnEmpty</a></div>
<div><a href="#option-forceHelperSize">forceHelperSize</a></div>
<div><a href="#option-forcePlaceholderSize">forcePlaceholderSize</a></div>
<div><a href="#option-grid">grid</a></div>
<div><a href="#option-handle">handle</a></div>
<div><a href="#option-helper">helper</a></div>
<div><a href="#option-items">items</a></div>
<div><a href="#option-opacity">opacity</a></div>
<div><a href="#option-placeholder">placeholder</a></div>
<div><a href="#option-revert">revert</a></div>
<div><a href="#option-scroll">scroll</a></div>
<div><a href="#option-scrollSensitivity">scrollSensitivity</a></div>
<div><a href="#option-scrollSpeed">scrollSpeed</a></div>
<div><a href="#option-tolerance">tolerance</a></div>
<div><a href="#option-zIndex">zIndex</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-cancel">cancel</a></div>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-refresh">refresh</a></div>
<div><a href="#method-refreshPositions">refreshPositions</a></div>
<div><a href="#method-serialize">serialize</a></div>
<div><a href="#method-toArray">toArray</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
<div><a href="#event-start">start</a></div>
<div><a href="#event-sort">sort</a></div>
<div><a href="#event-change">change</a></div>
<div><a href="#event-beforeStop">beforeStop</a></div>
<div><a href="#event-stop">stop</a></div>
<div><a href="#event-update">update</a></div>
<div><a href="#event-receive">receive</a></div>
<div><a href="#event-remove">remove</a></div>
<div><a href="#event-over">over</a></div>
<div><a href="#event-out">out</a></div>
<div><a href="#event-activate">activate</a></div>
<div><a href="#event-deactivate">deactivate</a></div>
</div></section><article id="sortable1" class="entry widget"><h2 class="section-title">
<span>Sortable Widget</span><span class="version-details">version added: 1.0</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Reorder elements in a list or grid using the mouse.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-appendTo" class="api-item first-item">
<h3>appendTo<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#jQuery">jQuery</a> or <a href="http://api.jquery.com/Types#Element">Element</a> or <a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"parent"</code>
</div>
<div>Defines where the helper that moves with the mouse is being appended to during the drag (for example, to resolve overlap/zIndex issues).</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>jQuery</strong>: A jQuery object containing the element to append the helper to.</li>
<li>
<strong>Element</strong>: The element to append the helper to.</li>
<li>
<strong>Selector</strong>: A selector specifying which element to append the helper to.</li>
<li>
<strong>String</strong>: The string <code>"parent"</code> will cause the helper to be a sibling of the sortable item.</li>
</ul>
</div>
<div id="option-axis" class="api-item">
<h3>axis<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If defined, the items can be dragged only horizontally or vertically. Possible values: <code>"x"</code>, <code>"y"</code>.</div>
</div>
<div id="option-cancel" class="api-item">
<h3>cancel<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>":input,button"</code>
</div>
<div>Prevents sorting if you start on elements matching the selector.</div>
</div>
<div id="option-connectWith" class="api-item">
<h3>connectWith<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>A selector of other sortable elements that the items from this list should be connected to. This is a one-way relationship, if you want the items to be connected in both directions, the <code>connectWith</code> option must be set on both sortable elements.</div>
</div>
<div id="option-containment" class="api-item">
<h3>containment<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Element">Element</a> or <a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>
<p>Defines a bounding box that the sortable items are contrained to while dragging.</p>
<p>Note: The element specified for containment must have a calculated width and height (though it need not be explicit). For example, if you have <code>float: left</code> sortable children and specify <code>containment: "parent"</code> be sure to have <code>float: left</code> on the sortable/parent container as well or it will have <code>height: 0</code>, causing undefined behavior.</p>
</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Element</strong>: An element to use as the container.</li>
<li>
<strong>Selector</strong>: A selector specifying an element to use as the container.</li>
<li>
<strong>String</strong>: A string identifying an element to use as the container. Possible values: <code>"parent"</code>, <code>"document"</code>, <code>"window"</code>.</li>
</ul>
</div>
<div id="option-cursor" class="api-item">
<h3>cursor<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"auto"</code>
</div>
<div>Defines the cursor that is being shown while sorting.</div>
</div>
<div id="option-cursorAt" class="api-item">
<h3>cursorAt<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Moves the sorting element or helper so the cursor always appears to drag from the same position. Coordinates can be given as a hash using a combination of one or two keys: <code>{ top, left, right, bottom }</code>.</div>
</div>
<div id="option-delay" class="api-item">
<h3>delay<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>0</code>
</div>
<div>Time in milliseconds to define when the sorting should start. Adding a delay helps preventing unwanted drags when clicking on an element.</div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the sortable if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the sortable with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).sortable({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).sortable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).sortable( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-distance" class="api-item">
<h3>distance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1</code>
</div>
<div>Tolerance, in pixels, for when sorting should start. If specified, sorting will not start until after mouse is dragged beyond distance. Can be used to allow for clicks on elements within a handle.</div>
</div>
<div id="option-dropOnEmpty" class="api-item">
<h3>dropOnEmpty<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>If <code>false</code>, items from this sortable can't be dropped on an empty connect sortable (see the <a href="#option-connectWith"><code>connectWith</code></a> option.</div>
</div>
<div id="option-forceHelperSize" class="api-item">
<h3>forceHelperSize<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If <code>true</code>, forces the helper to have a size.</div>
</div>
<div id="option-forcePlaceholderSize" class="api-item">
<h3>forcePlaceholderSize<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>If true, forces the placeholder to have a size.</div>
</div>
<div id="option-grid" class="api-item">
<h3>grid<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Array">Array</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Snaps the sorting element or helper to a grid, every x and y pixels. Array values: <code>[ x, y ]</code>.</div>
</div>
<div id="option-handle" class="api-item">
<h3>handle<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#Element">Element</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Restricts sort start click to the specified element.</div>
</div>
<div id="option-helper" class="api-item">
<h3>helper<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types/#Function">Function</a>()</span>
</h3>
<div class="default">
<strong>Default: </strong><code>"original"</code>
</div>
<div>Allows for a helper element to be used for dragging display.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>String</strong>: If set to <code>"clone"</code>, then the element will be cloned and the clone will be dragged.</li>
<li>
<strong>Function</strong>: A function that will return a DOMElement to use while dragging. The function receives the event and the element being sorted.</li>
</ul>
</div>
<div id="option-items" class="api-item">
<h3>items<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"> *"</code>
</div>
<div>Specifies which items inside the element should be sortable.</div>
</div>
<div id="option-opacity" class="api-item">
<h3>opacity<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Defines the opacity of the helper while sorting. From <code>0.01</code> to <code>1</code>.</div>
</div>
<div id="option-placeholder" class="api-item">
<h3>placeholder<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>A class name that gets applied to the otherwise white space.</div>
</div>
<div id="option-revert" class="api-item">
<h3>revert<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Whether the sortable items should revert to their new positions using a smooth animation.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>: When set to <code>true</code>, the items will animate with the default duration.</li>
<li>
<strong>Number</strong>: The duration for the animation, in milliseconds.</li>
</ul>
</div>
<div id="option-scroll" class="api-item">
<h3>scroll<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>true</code>
</div>
<div>If set to true, the page scrolls when coming to an edge.</div>
</div>
<div id="option-scrollSensitivity" class="api-item">
<h3>scrollSensitivity<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>20</code>
</div>
<div>Defines how near the mouse must be to an edge to start scrolling.</div>
</div>
<div id="option-scrollSpeed" class="api-item">
<h3>scrollSpeed<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Number">Number</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>20</code>
</div>
<div>The speed at which the window should scroll once the mouse pointer gets within the <a href="#option-scrollSensitivity"><code>scrollSensitivity</code></a> distance.</div>
</div>
<div id="option-tolerance" class="api-item">
<h3>tolerance<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>"intersect"</code>
</div>
<div>
Specifies which mode to use for testing whether the item being moved is hovering over another item. Possible values:
<ul>
<li>
<code>"intersect"</code>: The item overlaps the other item by at least 50%.</li>
<li>
<code>"pointer"</code>: The mouse pointer overlaps the other item.</li>
</ul>
</div>
</div>
<div id="option-zIndex" class="api-item">
<h3>zIndex<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Integer">Integer</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>1000</code>
</div>
<div>Z-index for element/helper while being sorted.</div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-cancel"><div class="api-item first-item">
<h3>cancel()</h3>
<div>Cancels a change in the current sortable and reverts it to the state prior to when the current sort was started. Useful in the stop and receive callback functions.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-destroy"><div class="api-item">
<h3>destroy()</h3>
<div>
Removes the sortable functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the sortable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the sortable.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current sortable options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the sortable option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the sortable.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-refresh"><div class="api-item">
<h3>refresh()</h3>
<div>Refresh the sortable items. Triggers the reloading of all sortable items, causing new items to be recognized.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-refreshPositions"><div class="api-item">
<h3>refreshPositions()</h3>
<div>Refresh the cached positions of the sortable items. Calling this method refreshes the cached item positions of all sortables.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-serialize"><div class="api-item">
<h3>serialize( options )</h3>
<div>
<p>Serializes the sortable's item <code>id</code>s into a form/ajax submittable string. Calling this method produces a hash that can be appended to any url to easily submit a new item order back to the server.</p>
<p>It works by default by looking at the <code>id</code> of each item in the format <code>"setname_number"</code>, and it spits out a hash like <code>"setname[]=number&setname[]=number"</code>.</p>
<p><em>Note: If serialize returns an empty string, make sure the <code>id</code> attributes include an underscore. They must be in the form: <code>"set_number"</code> For example, a 3 element list with <code>id</code> attributes <code>"foo_1"</code>, <code>"foo_5"</code>, <code>"foo_2"</code> will serialize to <code>"foo[]=1&foo[]=5&foo[]=2"</code>. You can use an underscore, equal sign or hyphen to separate the set and number. For example <code>"foo=1"</code>, <code>"foo-1"</code>, and <code>"foo_1"</code> all serialize to <code>"foo[]=1"</code>.</em></p>
</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>Options to customize the serialization.</div>
<ul>
<li>
<div><strong>key</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>Replaces <code>part1[]</code> with the specified value.</div>
</li>
<li>
<div><strong>attribute</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the attribute to use for the values.</div>
</li>
<li>
<div><strong>expression</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#RegExp">RegExp</a>
</div>
<div>A regular expression used to split the attribute value into key and value parts.</div>
</li>
</ul>
</li></ul>
</div></div>
<div id="method-toArray"><div class="api-item">
<h3>toArray()</h3>
<div>Serializes the sortable's item id's into an array of string.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the sortable element.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-activate" class="api-item first-item">
<h3>activate( event, ui )</h3>
<div>This event is triggered when using connected lists, every connected list on drag start receives it.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-beforeStop" class="api-item">
<h3>beforeStop( event, ui )</h3>
<div>This event is triggered when sorting stops, but when the placeholder/helper is still available.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-change" class="api-item">
<h3>change( event, ui )</h3>
<div>This event is triggered during sorting, but only when the DOM position has changed.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the sortable is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-deactivate" class="api-item">
<h3>deactivate( event, ui )</h3>
<div>This event is triggered when sorting was stopped, is propagated to all possible connected lists.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-out" class="api-item">
<h3>out( event, ui )</h3>
<div>This event is triggered when a sortable item is moved away from a connected list.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-over" class="api-item">
<h3>over( event, ui )</h3>
<div>This event is triggered when a sortable item is moved into a connected list.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-receive" class="api-item">
<h3>receive( event, ui )</h3>
<div>This event is triggered when a connected sortable list has received an item from another list.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-remove" class="api-item">
<h3>remove( event, ui )</h3>
<div>This event is triggered when a sortable item has been dragged out from the list and into another.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-sort" class="api-item">
<h3>sort( event, ui )</h3>
<div>This event is triggered during sorting.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-start" class="api-item">
<h3>start( event, ui )</h3>
<div>This event is triggered when sorting starts.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-stop" class="api-item">
<h3>stop( event, ui )</h3>
<div>This event is triggered when sorting has stopped.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div>
<div id="event-update" class="api-item">
<h3>update( event, ui )</h3>
<div>This event is triggered when the user stopped sorting and the DOM position has changed.</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div><strong>helper</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the helper being sorted</div>
</li>
<li>
<div><strong>item</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The jQuery object representing the current dragged element</div>
</li>
<li>
<div><strong>offset</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current absolute position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>position</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The current position of the helper represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>originalPosition</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The original position of the element represented as <code>{ top, left }</code>
</div>
</li>
<li>
<div><strong>sender</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The sortable that the item comes from if moving from one sortable to another</div>
</li>
</ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>The jQuery UI Sortable plugin makes selected elements sortable by dragging with the mouse.</p>
<p><em>Note: In order to sort table rows, the <code>tbody</code> must be made sortable, not the <code>table</code>.</em></p>
</div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Sortable.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>sortable demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">ul</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"sortable"</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 1</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 2</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 3</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 4</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">li</code><code class="plain">>Item 5</</code><code class="keyword">li</code><code class="plain">></code></div><div class="line number18 index17 alt1"><code class="plain"></</code><code class="keyword">ul</code><code class="plain">></code></div><div class="line number19 index18 alt2"> </div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">>$("#sortable").sortable();</</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="150"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/sortable.html | HTML | bsd | 50,684 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI clip-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Clip Effect",
"excerpt":
"\n\t\tThe clip effect will hide or show an element by clipping the element vertically or horizontally.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="clip1" class="entry effect"><h2 class="section-title"><span>Clip Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The clip effect will hide or show an element by clipping the element vertically or horizontally.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">clip</h4>
<ul><li>
<div>
<strong>direction</strong> (default: <code>"up"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>
<p>The plane in which the clip effect will hide or show its element.</p>
<p><code>vertical</code> clips the top and bottom edges, while <code>horizontal</code> clips the right and left edges.</p>
</div>
</li></ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the clip effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>clip demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "clip" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/clip-effect.html | HTML | bsd | 8,737 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI position documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
".position()",
"excerpt":
"Position an element relative to another.",
"termSlugs": {
"category": [
"methods","overrides","utilities"
]
}
}</script><article id="position1" class="entry method"><h2 class="section-title">
<span class="name">.position( options )</span> <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span><span class="version-details">version added: 1.8</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Position an element relative to another.</p>
<ul class="signatures"><li class="signature" id="position-options">
<h4 class="name">.position( options )</h4>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul>
<li>
<div>
<strong>my</strong> (default: <code>"center"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>Defines which position <strong>on the element being positioned</strong> to align with the target element: "horizontal vertical" alignment. A single value such as <code>"right"</code> will be normalized to <code>"right center"</code>, <code>"top"</code> will be normalized to <code>"center top"</code> (following CSS convention). Acceptable horizontal values: <code>"left"</code>, <code>"center"</code>, <code>"right"</code>. Acceptable vertical values: <code>"top"</code>, <code>"center"</code>, <code>"bottom"</code>. Example: <code>"left top"</code> or <code>"center center"</code>. Each dimension can also contain offsets, in pixels or percent, e.g., <code>"right+10 top-25%"</code>. Percentage offsets are relative to the element being positioned.</div>
</li>
<li>
<div>
<strong>at</strong> (default: <code>"center"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>Defines which position <strong>on the target element</strong> to align the positioned element against: "horizontal vertical" alignment. See the <a href="#option-my"><code>my</code></a> option for full details on possible values. Perecentage offsets are relative to the target element.</div>
</li>
<li>
<div>
<strong>of</strong> (default: <code>null</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#Element">Element</a> or <a href="http://api.jquery.com/Types#jQuery">jQuery</a> or <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>Which element to position against. If you provide a selector or jQuery object, the first matching element will be used. If you provide an event object, the <code>pageX</code> and <code>pageY</code> properties will be used. Example: <code>"#top-menu"</code>
</div>
</li>
<li>
<div>
<strong>collision</strong> (default: <code>"flip"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>
<p>When the positioned element overflows the window in some direction, move it to an alternative position. Similar to <a href="#option-my"><code>my</code></a> and <a href="#option-at"><code>at</code></a>, this accepts a single value or a pair for horizontal/vertical, e.g., <code>"flip"</code>, <code>"fit"</code>, <code>"fit flip"</code>, <code>"fit none"</code>.</p>
<ul>
<li>
<code>"flip"</code>: Flips the element to the opposite side of the target and the collision detection is run again to see if it will fit. Whichever side allows more of the element to be visible will be used.</li>
<li>
<code>"fit"</code>: Shift the element away from the edge of the window.</li>
<li>
<code>"flipfit"</code>: First applies the flip logic, placing the element on whichever side allows more of the element to be visible. Then the fit logic is applied to ensure as much of the element is visible as possible.</li>
<li>
<code>"none"</code>: Does not apply any collision detection.</li>
</ul>
</div>
</li>
<li>
<div>
<strong>using</strong> (default: <code>null</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types/#Function">Function</a>()</div>
<div>
When specified, the actual property setting is delegated to this callback. Receives two parameters: The first is a hash of <code>top</code> and <code>left</code> values for the position that should be set and can be forwarded to <code>.position()</code> or <code>.animate()</code>.
<p>The second provides feedback about the position and dimensions of both elements, as well as calculations to their relative position. Both <code>target</code> and <code>element</code> have these properties: <code>element</code>, <code>left</code>, <code>top</code>, <code>width</code>, <code>height</code>. In addition, there's <code>horizontal</code>, <code>vertical</code> and <code>important</code>, giving you twelve potential directions like <code>{ horizontal: "center", vertical: "left", important: "horizontal" }</code>.</p>
</div>
</li>
<li>
<div>
<strong>within</strong> (default: <code>window</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Selector">Selector</a> or <a href="http://api.jquery.com/Types#Element">Element</a> or <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>Element to position within, affecting collision detection. If you provide a selector or jQuery object, the first matching element will be used.</div>
</li>
</ul>
</li></ul>
</li></ul>
<div class="longdesc" id="entry-longdesc">
<p>The jQuery UI <code>.position()</code> method allows you to position an element relative to the window, document, another element, or the cursor/mouse, without worrying about offset parents.</p>
<p><em>Note: jQuery UI does not support positioning hidden elements.</em></p>
<p>This is a standalone jQuery plugin and has no dependencies on other jQuery UI components.</p>
<p>This plugin extends jQuery's built-in <a href="http://api.jquery.com/position"><code>.position()</code></a> method. If jQuery UI is not loaded, calling the <code>.position()</code> method may not fail directly, as the method still exists. However, the expected behavior will not occur.</p>
</div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">A simple jQuery UI Position example.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div><div class="line number30 index29 alt1">30</div><div class="line number31 index30 alt2">31</div><div class="line number32 index31 alt1">32</div><div class="line number33 index32 alt2">33</div><div class="line number34 index33 alt1">34</div><div class="line number35 index34 alt2">35</div><div class="line number36 index35 alt1">36</div><div class="line number37 index36 alt2">37</div><div class="line number38 index37 alt1">38</div><div class="line number39 index38 alt2">39</div><div class="line number40 index39 alt1">40</div><div class="line number41 index40 alt2">41</div><div class="line number42 index41 alt1">42</div><div class="line number43 index42 alt2">43</div><div class="line number44 index43 alt1">44</div><div class="line number45 index44 alt2">45</div><div class="line number46 index45 alt1">46</div><div class="line number47 index46 alt2">47</div><div class="line number48 index47 alt1">48</div><div class="line number49 index48 alt2">49</div><div class="line number50 index49 alt1">50</div><div class="line number51 index50 alt2">51</div><div class="line number52 index51 alt1">52</div><div class="line number53 index52 alt2">53</div><div class="line number54 index53 alt1">54</div><div class="line number55 index54 alt2">55</div><div class="line number56 index55 alt1">56</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>position demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">.positionDiv {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">position: absolute;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">width: 75px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">height: 75px;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">background: green;</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number18 index17 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number19 index18 alt2"> </div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"targetElement"</code><code class="plain">></code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code> <code class="color1">class</code><code class="plain">=</code><code class="string">"positionDiv"</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"position1"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code> <code class="color1">class</code><code class="plain">=</code><code class="string">"positionDiv"</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"position2"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code> <code class="color1">class</code><code class="plain">=</code><code class="string">"positionDiv"</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"position3"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">div</code> <code class="color1">class</code><code class="plain">=</code><code class="string">"positionDiv"</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"position4"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number25 index24 alt2"><code class="plain"></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number26 index25 alt1"> </div><div class="line number27 index26 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number28 index27 alt1"><code class="plain">$( "#position1" ).position({</code></div><div class="line number29 index28 alt2"><code class="undefined spaces"> </code><code class="plain">my: "center",</code></div><div class="line number30 index29 alt1"><code class="undefined spaces"> </code><code class="plain">at: "center",</code></div><div class="line number31 index30 alt2"><code class="undefined spaces"> </code><code class="plain">of: "#targetElement"</code></div><div class="line number32 index31 alt1"><code class="plain">});</code></div><div class="line number33 index32 alt2"> </div><div class="line number34 index33 alt1"><code class="plain">$( "#position2" ).position({</code></div><div class="line number35 index34 alt2"><code class="undefined spaces"> </code><code class="plain">my: "left top",</code></div><div class="line number36 index35 alt1"><code class="undefined spaces"> </code><code class="plain">at: "left top",</code></div><div class="line number37 index36 alt2"><code class="undefined spaces"> </code><code class="plain">of: "#targetElement"</code></div><div class="line number38 index37 alt1"><code class="plain">});</code></div><div class="line number39 index38 alt2"> </div><div class="line number40 index39 alt1"><code class="plain">$( "#position3" ).position({</code></div><div class="line number41 index40 alt2"><code class="undefined spaces"> </code><code class="plain">my: "right center",</code></div><div class="line number42 index41 alt1"><code class="undefined spaces"> </code><code class="plain">at: "right bottom",</code></div><div class="line number43 index42 alt2"><code class="undefined spaces"> </code><code class="plain">of: "#targetElement"</code></div><div class="line number44 index43 alt1"><code class="plain">});</code></div><div class="line number45 index44 alt2"> </div><div class="line number46 index45 alt1"><code class="plain">$( document ).mousemove(function( event ) {</code></div><div class="line number47 index46 alt2"><code class="undefined spaces"> </code><code class="plain">$( "#position4" ).position({</code></div><div class="line number48 index47 alt1"><code class="undefined spaces"> </code><code class="plain">my: "left+3 bottom-3",</code></div><div class="line number49 index48 alt2"><code class="undefined spaces"> </code><code class="plain">of: event,</code></div><div class="line number50 index49 alt1"><code class="undefined spaces"> </code><code class="plain">collision: "fit"</code></div><div class="line number51 index50 alt2"><code class="undefined spaces"> </code><code class="plain">});</code></div><div class="line number52 index51 alt1"><code class="plain">});</code></div><div class="line number53 index52 alt2"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number54 index53 alt1"> </div><div class="line number55 index54 alt2"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number56 index55 alt1"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/position.html | HTML | bsd | 19,854 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI pulsate-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Pulsate Effect",
"excerpt":
"\n\t\tThe pulsate effect hides or shows an element by pulsing it in or out.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="pulsate1" class="entry effect"><h2 class="section-title"><span>Pulsate Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The pulsate effect hides or shows an element by pulsing it in or out.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">pulsate</h4>
<ul><li>
<div>
<strong>times</strong> (default: <code>5</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Integer">Integer</a>
</div>
<div>The number of times the element should pulse. An extra half pulse is added for hide/show.</div>
</li></ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the pulsate effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>pulsate demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "pulsate" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/pulsate-effect.html | HTML | bsd | 8,583 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI blind-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Blind Effect",
"excerpt":
"\n\t\tThe blind effect hides or shows an element by wrapping the element in a container, and \"pulling the blinds\"\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="blind1" class="entry effect"><h2 class="section-title"><span>Blind Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The blind effect hides or shows an element by wrapping the element in a container, and "pulling the blinds"
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">blind</h4>
<ul><li>
<div>
<strong>direction</strong> (default: <code>"up"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>
<p>The direction the blind will be pulled to hide the element, or the direction from which the element will be revealed.</p>
<p>Possible Values: <code>up</code>, <code>down</code>, <code>left</code>, <code>right</code>, <code>vertical</code>, <code>horizontal</code>.</p>
</div>
</li></ul>
</li></ul>
<div class="longdesc" id="entry-longdesc">
<p>The container has <code>overflow: hidden</code> applied, so height changes affect what's visible.</p>
</div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the blind effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>blind demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "blind" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/blind-effect.html | HTML | bsd | 9,003 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI bounce-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Bounce Effect",
"excerpt":
"\n\t\tThe bounce effect bounces an element. When used with hide or show, the last or first bounce will also fade in/out.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="bounce1" class="entry effect"><h2 class="section-title"><span>Bounce Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
The bounce effect bounces an element. When used with hide or show, the last or first bounce will also fade in/out.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">bounce</h4>
<ul>
<li>
<div>
<strong>distance</strong> (default: <code>20</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The distance of the largest "bounce" in pixels.</div>
</li>
<li>
<div>
<strong>times</strong> (default: <code>5</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Integer">Integer</a>
</div>
<div>The number of times the element will bounce. When used with hide or show, there is an extra "half" bounce for the fade in/out.</div>
</li>
</ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Example:</h2></header><div class="entry-example" id="example-0">
<h4><span class="desc">Toggle a div using the bounce effect.</span></h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>bounce demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "bounce", { times: 3 }, "slow" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/bounce-effect.html | HTML | bsd | 8,937 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI scale-effect documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Scale Effect",
"excerpt":
"\n\t\tShrink or grow an element by a percentage factor.\n\t",
"termSlugs": {
"category": [
"effects"
]
}
}</script><article id="scale1" class="entry effect"><h2 class="section-title"><span>Scale Effect</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>
Shrink or grow an element by a percentage factor.
</p>
<ul class="signatures"><li class="signature">
<h4 class="name">scale</h4>
<ul>
<li>
<div>
<strong>direction</strong> (default: <code>"both"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The direction of the effect. Possible values: <code>"both"</code>, <code>"vertical"</code> or <code>"horizontal"</code>.</div>
</li>
<li>
<div>
<strong>origin</strong> (default: <code>[ "middle", "center" ]</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#Array">Array</a>
</div>
<div>The vanishing point.</div>
</li>
<li>
<div><strong>percent</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The percentage to scale to.</div>
</li>
<li>
<div>
<strong>scale</strong> (default: <code>"both"</code>)</div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>Which areas of the element will be resized: <code>"both"</code>, <code>"box"</code>, <code>"content"</code>. Box resizes the border and padding of the element; content resizes any content inside of the element.</div>
</li>
</ul>
</li></ul>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Examples:</h2></header><div class="entry-example" id="example-0">
<h4>Example: <span class="desc">Toggle a div using the scale effect.</span>
</h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>scale demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle( "scale" );</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div>
<div class="entry-example" id="example-1">
<h4>Example: <span class="desc">Toggle a div using the scale effect in just one direction.</span>
</h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div><div class="line number28 index27 alt1">28</div><div class="line number29 index28 alt2">29</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>scale demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain">#toggle {</code></div><div class="line number9 index8 alt2"><code class="undefined spaces"> </code><code class="plain">width: 100px;</code></div><div class="line number10 index9 alt1"><code class="undefined spaces"> </code><code class="plain">height: 100px;</code></div><div class="line number11 index10 alt2"><code class="undefined spaces"> </code><code class="plain">background: #ccc;</code></div><div class="line number12 index11 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"></</code><code class="keyword">style</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number18 index17 alt1"> </div><div class="line number19 index18 alt2"><code class="plain"><</code><code class="keyword">p</code><code class="plain">>Click anywhere to toggle the box.</</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number20 index19 alt1"><code class="plain"><</code><code class="keyword">div</code> <code class="color1">id</code><code class="plain">=</code><code class="string">"toggle"</code><code class="plain">></</code><code class="keyword">div</code><code class="plain">></code></div><div class="line number21 index20 alt2"> </div><div class="line number22 index21 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number23 index22 alt2"><code class="plain">$( document ).click(function() {</code></div><div class="line number24 index23 alt1"><code class="undefined spaces"> </code><code class="plain">$( "#toggle" ).toggle({ effect: "scale", direction: "horizontal" });</code></div><div class="line number25 index24 alt2"><code class="plain">});</code></div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number27 index26 alt2"> </div><div class="line number28 index27 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number29 index28 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="200"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/scale-effect.html | HTML | bsd | 16,721 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI tooltip documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Tooltip Widget",
"excerpt":
"Customizable, themeable tooltips, replacing native tooltips.",
"termSlugs": {
"category": [
"widgets"
]
}
}</script><section class="quick-nav"><header><h2>QuickNav<a href="#entry-longdesc">Overview</a><a href="#entry-examples">Examples</a>
</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-content">content</a></div>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-hide">hide</a></div>
<div><a href="#option-items">items</a></div>
<div><a href="#option-position">position</a></div>
<div><a href="#option-show">show</a></div>
<div><a href="#option-tooltipClass">tooltipClass</a></div>
<div><a href="#option-track">track</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-close">close</a></div>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-open">open</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
<div><a href="#event-open">open</a></div>
<div><a href="#event-close">close</a></div>
</div></section><article id="tooltip1" class="entry widget"><h2 class="section-title">
<span>Tooltip Widget</span><span class="version-details">version added: 1.9</span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Customizable, themeable tooltips, replacing native tooltips.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-content" class="api-item first-item">
<h3>content<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types/#Function">Function</a>() or <a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>function returning the title attribute</code>
</div>
<div>
<p>The content of the tooltip.</p>
<p><em>When changing this option, you likely need to also change the <a href="#option-items"><code>items</code></a> option.</em></p>
</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Function</strong>: A callback which can either return the content directly, or call the first argument, passing in the content, e.g., for Ajax content.</li>
<li>
<strong>String</strong>: A string of HTML to use for the tooltip content.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the tooltip with the content option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip({ content: </code><code class="string">"Awesome title!"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the content option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">content = $( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"content"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"content"</code><code class="plain">, </code><code class="string">"Awesome title!"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-disabled" class="api-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the tooltip if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the tooltip with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-hide" class="api-item">
<h3>hide<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>If and how to animate the hiding of the tooltip.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>:
When set to <code>false</code>, no animation will be used and the tooltip will be hidden immediately.
When set to <code>true</code>, the tooltip will fade out with the default duration and the default easing.
</li>
<li>
<strong>Number</strong>:
The tooltip will fade out with the specified duration and the default easing.
</li>
<li>
<strong>String</strong>:
The tooltip will be hidden using the specified effect.
The value can either be the name of a built-in jQuery animateion method, such as <code>"slideUp"</code>, or the name of a jQuery UI effect, such as <code>"fold"</code>.
In either case the effect will be used with the default duration and the default easing.
</li>
<li>
<strong>Object</strong>: If the value is an object, then <code>effect</code>, <code>duration</code>, and <code>easing</code> properties may be provided. If the <code>effect</code> property contains the name of a jQuery method, then that method will be used; otherwise it is assumed to be the name of a jQuery UI effect. When using a jQuery UI effect that supports additional settings, you may include those settings in the object and they will be passed to the effect. If <code>duration</code> or <code>easing</code> is omitted, then the default values will be used. If <code>effect</code> is omitted, then <code>"fadeOut"</code> will be used.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the tooltip with the hide option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip({ hide: { effect: </code><code class="string">"explode"</code><code class="plain">, duration: 1000 } });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the hide option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">hide = $( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"hide"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"hide"</code><code class="plain">, { effect: </code><code class="string">"explode"</code><code class="plain">, duration: 1000 } );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-items" class="api-item">
<h3>items<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Selector">Selector</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>[title]</code>
</div>
<div>
<p>A selector indicating which items should show tooltips. Customize if you're using something other then the title attribute for the tooltip content, or if you need a different selector for event delegation.</p>
<p><em>When changing this option, you likely need to also change the <a href="#option-content"><code>content</code></a> option.</em></p>
</div>
<strong>Code examples:</strong><p>Initialize the tooltip with the items option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip({ items: </code><code class="string">"img[alt]"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the items option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">items = $( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"items"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"items"</code><code class="plain">, </code><code class="string">"img[alt]"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-position" class="api-item">
<h3>position<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>{ my: "left+15 center", at: "right center", collision: "flipfit" }</code>
</div>
<div>Configuration for the Position utility. The <code>of</code> property defaults to the target element, but can also be overriden.</div>
<strong>Code examples:</strong><p>Initialize the tooltip with the position option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip({ position: { my: </code><code class="string">"center top"</code><code class="plain">, at: </code><code class="string">"center bottom+5"</code> <code class="plain">} });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the position option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">position = $( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"position"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"position"</code><code class="plain">, { my: </code><code class="string">"center top"</code><code class="plain">, at: </code><code class="string">"center bottom+5"</code> <code class="plain">} );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-show" class="api-item">
<h3>show<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>If and how to animate the showing of the tooltip.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>:
When set to <code>false</code>, no animation will be used and the tooltip will be shown immediately.
When set to <code>true</code>, the tooltip will fade in with the default duration and the default easing.
</li>
<li>
<strong>Number</strong>:
The tooltip will fade in with the specified duration and the default easing.
</li>
<li>
<strong>String</strong>:
The tooltip will be shown using the specified effect.
The value can either be the name of a built-in jQuery animateion method, such as <code>"slideDown"</code>, or the name of a jQuery UI effect, such as <code>"fold"</code>.
In either case the effect will be used with the default duration and the default easing.
</li>
<li>
<strong>Object</strong>: If the value is an object, then <code>effect</code>, <code>duration</code>, and <code>easing</code> properties may be provided. If the <code>effect</code> property contains the name of a jQuery method, then that method will be used; otherwise it is assumed to be the name of a jQuery UI effect. When using a jQuery UI effect that supports additional settings, you may include those settings in the object and they will be passed to the effect. If <code>duration</code> or <code>easing</code> is omitted, then the default values will be used. If <code>effect</code> is omitted, then <code>"fadeIn"</code> will be used.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the tooltip with the show option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip({ show: { effect: </code><code class="string">"blind"</code><code class="plain">, duration: 800 } });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the show option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">show = $( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"show"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"show"</code><code class="plain">, { effect: </code><code class="string">"blind"</code><code class="plain">, duration: 800 } );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-tooltipClass" class="api-item">
<h3>tooltipClass<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#String">String</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>
A class to add to the widget, can be used to display various tooltip types, like warnings or errors.
<p>This may get replaced by the <a href="http://bugs.jqueryui.com/ticket/7053">classes option</a>.</p>
</div>
<strong>Code examples:</strong><p>Initialize the tooltip with the tooltipClass option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip({ tooltipClass: </code><code class="string">"custom-tooltip-styling"</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the tooltipClass option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">tooltipClass = $( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"tooltipClass"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"tooltipClass"</code><code class="plain">, </code><code class="string">"custom-tooltip-styling"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-track" class="api-item">
<h3>track<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>
Whether the tooltip should track (follow) the mouse.
</div>
<strong>Code examples:</strong><p>Initialize the tooltip with the track option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip({ track: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the track option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">track = $( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"track"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).tooltip( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"track"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-close"><div class="api-item first-item">
<h3>close()</h3>
<div>
Closes a tooltip. This is only intended to be called for non-delegated tooltips.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-destroy"><div class="api-item">
<h3>destroy()</h3>
<div>
Removes the tooltip functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the tooltip.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the tooltip.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-open"><div class="api-item">
<h3>open()</h3>
<div>
Programmatically open a tooltip. This is only intended to be called for non-delegated tooltips.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current tooltip options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the tooltip option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the tooltip.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the original element.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-close" class="api-item first-item">
<h3>close( event, ui )</h3>
<div>
Triggered when a tooltip is closed, triggered on <code>focusout</code> or <code>mouseleave</code>.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>tooltip</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The generated tooltip element.</div>
</li></ul>
</li>
</ul>
</div>
<div id="event-create" class="api-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the tooltip is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div>
<div id="event-open" class="api-item">
<h3>open( event, ui )</h3>
<div>
Triggered when a tooltip is shown, triggered on <code>focusin</code> or <code>mouseover</code>.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
<ul><li>
<div><strong>tooltip</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The generated tooltip element.</div>
</li></ul>
</li>
</ul>
</div></section><div class="longdesc" id="entry-longdesc">
<p>Tooltip replaces native tooltips, making them themable as well as allowing various customizations:</p>
<ul>
<li>Display other content than just the title, like inline footnotes or extra content retrieved via Ajax.</li>
<li>Customize the positioning, e.g., to center the tooltip above elements.</li>
<li>Add extra styling to customize the appearance, for warning or error fields.</li>
</ul>
<p>A fade animation is used by default to show and hide the tooltip, making the appearance a bit more organic, compared to just toggling the visiblity. This can be customized with the <a href="#option-show"><code>show</code></a> and <a href="#option-hide"><code>hide</code></a> options.</p>
<p>The <a href="#option-items"><code>items</code></a> and <a href="#option-content"><code>content</code></a> options need to stay in-sync. If you change one of them, you need to change the other.</p>
</div>
<h3>Additional Notes:</h3>
<div class="longdesc"><ul><li>
This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
</li></ul></div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">Examples:</h2></header><div class="entry-example" id="example-0">
<h4>Example: <span class="desc">Create a tooltip on the document, using event delegation for all elements with a title attribute.</span>
</h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>tooltip demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">a</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"#"</code> <code class="color1">title</code><code class="plain">=</code><code class="string">"Anchor description"</code><code class="plain">>Anchor text</</code><code class="keyword">a</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">input</code> <code class="color1">title</code><code class="plain">=</code><code class="string">"Input help"</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="plain"></</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number16 index15 alt1"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number17 index16 alt2"><code class="undefined spaces"> </code><code class="plain">$( document ).tooltip();</code></div><div class="line number18 index17 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number19 index18 alt2"> </div><div class="line number20 index19 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number21 index20 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="80"></div>
</div>
<div class="entry-example" id="example-1">
<h4>Example: <span class="desc">Create a tooltip on the paragraph element, matching all images with an alt attribute. Use the alt attribute as the tooltip's content for each image.</span>
</h4>
<div class="syntaxhighlighter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="gutter"><div class="line number1 index0 alt2">1</div><div class="line number2 index1 alt1">2</div><div class="line number3 index2 alt2">3</div><div class="line number4 index3 alt1">4</div><div class="line number5 index4 alt2">5</div><div class="line number6 index5 alt1">6</div><div class="line number7 index6 alt2">7</div><div class="line number8 index7 alt1">8</div><div class="line number9 index8 alt2">9</div><div class="line number10 index9 alt1">10</div><div class="line number11 index10 alt2">11</div><div class="line number12 index11 alt1">12</div><div class="line number13 index12 alt2">13</div><div class="line number14 index13 alt1">14</div><div class="line number15 index14 alt2">15</div><div class="line number16 index15 alt1">16</div><div class="line number17 index16 alt2">17</div><div class="line number18 index17 alt1">18</div><div class="line number19 index18 alt2">19</div><div class="line number20 index19 alt1">20</div><div class="line number21 index20 alt2">21</div><div class="line number22 index21 alt1">22</div><div class="line number23 index22 alt2">23</div><div class="line number24 index23 alt1">24</div><div class="line number25 index24 alt2">25</div><div class="line number26 index25 alt1">26</div><div class="line number27 index26 alt2">27</div></td><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain"><!doctype html></code></div><div class="line number2 index1 alt1"><code class="plain"><</code><code class="keyword">html</code> <code class="color1">lang</code><code class="plain">=</code><code class="string">"en"</code><code class="plain">></code></div><div class="line number3 index2 alt2"><code class="plain"><</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">meta</code> <code class="color1">charset</code><code class="plain">=</code><code class="string">"utf-8"</code><code class="plain">></code></div><div class="line number5 index4 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">title</code><code class="plain">>tooltip demo</</code><code class="keyword">title</code><code class="plain">></code></div><div class="line number6 index5 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">link</code> <code class="color1">rel</code><code class="plain">=</code><code class="string">"stylesheet"</code> <code class="color1">href</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css">http://code.jquery.com/ui/1.9.1/themes/base/jquery-ui.css</a>"</code><code class="plain">></code></div><div class="line number7 index6 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/jquery-1.8.2.js">http://code.jquery.com/jquery-1.8.2.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number8 index7 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">script</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"<a href="http://code.jquery.com/ui/1.9.1/jquery-ui.js">http://code.jquery.com/ui/1.9.1/jquery-ui.js</a>"</code><code class="plain">></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number9 index8 alt2"><code class="plain"></</code><code class="keyword">head</code><code class="plain">></code></div><div class="line number10 index9 alt1"><code class="plain"><</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number11 index10 alt2"> </div><div class="line number12 index11 alt1"><code class="plain"><</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number13 index12 alt2"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">img</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"/resources/images/st-stephens.jpg"</code> <code class="color1">alt</code><code class="plain">=</code><code class="string">"St. Stephen's Cathedral"</code><code class="plain">></code></div><div class="line number14 index13 alt1"><code class="undefined spaces"> </code><code class="plain"><</code><code class="keyword">img</code> <code class="color1">src</code><code class="plain">=</code><code class="string">"/resources/images/tower-bridge.jpg"</code> <code class="color1">alt</code><code class="plain">=</code><code class="string">"Tower Bridge"</code><code class="plain">></code></div><div class="line number15 index14 alt2"><code class="plain"></</code><code class="keyword">p</code><code class="plain">></code></div><div class="line number16 index15 alt1"> </div><div class="line number17 index16 alt2"><code class="plain"><</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number18 index17 alt1"><code class="plain">$( "p" ).tooltip({</code></div><div class="line number19 index18 alt2"><code class="undefined spaces"> </code><code class="plain">items: "img[alt]",</code></div><div class="line number20 index19 alt1"><code class="undefined spaces"> </code><code class="plain">content: function() {</code></div><div class="line number21 index20 alt2"><code class="undefined spaces"> </code><code class="plain">return $( this ).attr( "alt" );</code></div><div class="line number22 index21 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number23 index22 alt2"><code class="plain">});</code></div><div class="line number24 index23 alt1"><code class="plain"></</code><code class="keyword">script</code><code class="plain">></code></div><div class="line number25 index24 alt2"> </div><div class="line number26 index25 alt1"><code class="plain"></</code><code class="keyword">body</code><code class="plain">></code></div><div class="line number27 index26 alt2"><code class="plain"></</code><code class="keyword">html</code><code class="plain">></code></div></div></td></tr></tbody></table></div>
<h4>Demo:</h4>
<div class="demo code-demo" data-height="300"></div>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/tooltip.html | HTML | bsd | 42,150 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI jQuery documentation</title>
<style>
body {
font-family: "Trebuchet MS", "Arial", "Helvetica", "Verdana", "sans-serif"
}
.gutter {
display: none;
}
</style>
</head>
<body>
<script>{
"title":
"Widget Factory",
"excerpt":
"Create stateful jQuery plugins using the same abstraction as all jQuery UI widgets.",
"termSlugs": {
"category": [
"utilities","utilities","widgets"
]
}
}</script><div class="toc">
<h4><span>Contents:</span></h4>
<ul class="toc-list">
<li>
<a href="#jQuery-widget1">jQuery.widget( name [, base ], prototype )</a><ul><li>jQuery.widget( name [, base ], prototype )</li></ul>
</li>
<li><a href="#jQuery-Widget2">jQuery.Widget</a></li>
</ul>
</div><article id="jQuery-widget1" class="entry method"><h2 class="section-title"><span class="name">jQuery.widget( name [, base ], prototype )</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>Create stateful jQuery plugins using the same abstraction as all jQuery UI widgets.</p>
<ul class="signatures"><li class="signature" id="jQuery-widget-name-base-prototype">
<h4 class="name">jQuery.widget( name [, base ], prototype )</h4>
<ul>
<li>
<div><strong>name</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the widget to create, including the namespace.</div>
</li>
<li>
<div><strong>base</strong></div>
<div>Type: <a href="http://api.jquery.com/Types/#Function">Function</a>()</div>
<div>The base widget to inherit from. This must be a constructor that can be instantiated with the `new` keyword. Defaults to <code>jQuery.Widget</code>.</div>
</li>
<li>
<div><strong>prototype</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#PlainObject">PlainObject</a>
</div>
<div>The object to use as a prototype for the widget.</div>
</li>
</ul>
</li></ul>
<div class="longdesc" id="entry-longdesc">
<p>You can create new widgets from scratch, using just the <code>$.Widget</code> object as a base to inherit from, or you can explicitly inherit from existing jQuery UI or third-party widgets. Defining a widget with the same name as you inherit from even allows you to extend widgets in place.</p>
<p>jQuery UI contains many widgets that maintain state and therefore have a slightly different usage pattern than typical jQuery plugins. All of jQuery UI's widgets use the same patterns, which is defined by the widget factory. So if you learn how to use one widget, then you'll know how to use all of them.</p>
<p><em>Note: This documentation shows examples using the <a href="/progressbar">progressbar widget</a> but the syntax is the same for every widget.</em></p>
<h3>Initialization</h3>
<p>In order to track the state of the widget, we must introduce a full life cycle for the widget. The life cycle starts when the widget is initalized. To initialize a widget, we simply call the plugin on one or more elements.</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">"#elem"</code> <code class="plain">).progressbar();</code></div></div></td></tr></tbody></table></div>
<p>This will initialize each element in the jQuery object, in this case the element with an id of <code>"elem"</code>. Because we called the <code>progressbar()</code> method with no parameters, the widget is initialized with its default options. We can pass a set of options during initialization in order to override the default options.</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">"#elem"</code> <code class="plain">).progressbar({ value: 20 });</code></div></div></td></tr></tbody></table></div>
<p>We can pass as many or as few options as we want during initialization. Any options that we don't pass will just use their default values.</p>
<p>The options are part of the widget's state, so we can set options after initialization as well. We'll see this later with the option method.</p>
<h3>Methods</h3>
<p>Now that the widget is initialized, we can query its state or perform actions on the widget. All actions after initialization take the form of a method call. To call a method on a widget, we pass the name of the method to the jQuery plugin. For example, to call the <code>value()</code> method on our progressbar widget, we would use:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">"#elem"</code> <code class="plain">).progressbar( </code><code class="string">"value"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
<p>If the method accepts parameters, we can pass them after the method name. For example, to pass the parameter <code>40</code> to the <code>value()</code> method, we can use:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">"#elem"</code> <code class="plain">).progressbar( </code><code class="string">"value"</code><code class="plain">, 40 );</code></div></div></td></tr></tbody></table></div>
<p>Just like other methods in jQuery, most widget methods return the jQuery object for chaining.</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">"#elem"</code> <code class="plain">)</code></div><div class="line number2 index1 alt1"><code class="undefined spaces"> </code><code class="plain">.progressbar( </code><code class="string">"value"</code><code class="plain">, 90 )</code></div><div class="line number3 index2 alt2"><code class="undefined spaces"> </code><code class="plain">.addClass( </code><code class="string">"almost-done"</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
<p>Each widget will have its own set of methods based on the functionality that the widget provides. However, there are a few methods that exist on all widgets, which are documented below.</p>
<h3>Events</h3>
<p>All widgets have events associated with their various behaviors to notify you when the state is changing. For most widgets, when the events are triggered, the names are prefixed with the widget name. For example, we can bind to progressbar's <code>change</code> event which is triggered whenever the value changes.</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">"#elem"</code> <code class="plain">).bind( </code><code class="string">"progressbarchange"</code><code class="plain">, </code><code class="keyword">function</code><code class="plain">() {</code></div><div class="line number2 index1 alt1"><code class="undefined spaces"> </code><code class="plain">alert( </code><code class="string">"The value has changed!"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"><code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Each event has a corresponding callback, which is exposed as an option. We can hook into progressbar's <code>change</code> callback instead of binding to the <code>progressbarchange</code> event, if we want to.</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">"#elem"</code> <code class="plain">).progressbar({</code></div><div class="line number2 index1 alt1"><code class="undefined spaces"> </code><code class="plain">change: </code><code class="keyword">function</code><code class="plain">() {</code></div><div class="line number3 index2 alt2"><code class="undefined spaces"> </code><code class="plain">alert( </code><code class="string">"The value has changed!"</code> <code class="plain">);</code></div><div class="line number4 index3 alt1"><code class="undefined spaces"> </code><code class="plain">}</code></div><div class="line number5 index4 alt2"><code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>All widgets have a <code>create</code> event which is triggered upon instantiation.</p>
</div>
</div></article><section class="quick-nav"><header><h2>QuickNav</h2></header><div class="quick-nav-section">
<h3>Options</h3>
<div><a href="#option-disabled">disabled</a></div>
<div><a href="#option-hide">hide</a></div>
<div><a href="#option-show">show</a></div>
</div>
<div class="quick-nav-section">
<h3>Methods</h3>
<div><a href="#method-destroy">destroy</a></div>
<div><a href="#method-disable">disable</a></div>
<div><a href="#method-enable">enable</a></div>
<div><a href="#method-option">option</a></div>
<div><a href="#method-widget">widget</a></div>
<div><a href="#method-_create">_create</a></div>
<div><a href="#method-_destroy">_destroy</a></div>
<div><a href="#method-_getCreateEventData">_getCreateEventData</a></div>
<div><a href="#method-_getCreateOptions">_getCreateOptions</a></div>
<div><a href="#method-_init">_init</a></div>
<div><a href="#method-_setOptions">_setOptions</a></div>
<div><a href="#method-_setOption">_setOption</a></div>
<div><a href="#method-_on">_on</a></div>
<div><a href="#method-_off">_off</a></div>
<div><a href="#method-_super">_super</a></div>
<div><a href="#method-_superApply">_superApply</a></div>
<div><a href="#method-_delay">_delay</a></div>
<div><a href="#method-_hoverable">_hoverable</a></div>
<div><a href="#method-_focusable">_focusable</a></div>
<div><a href="#method-_trigger">_trigger</a></div>
<div><a href="#method-_show">_show</a></div>
<div><a href="#method-_hide">_hide</a></div>
</div>
<div class="quick-nav-section">
<h3>Events</h3>
<div><a href="#event-create">create</a></div>
</div></section><article id="jQuery-Widget2" class="entry widget"><h2 class="section-title"><span>Base Widget</span></h2>
<div class="entry-wrapper">
<p class="desc"><strong>Description: </strong>The base widget used by the widget factory.</p>
<section id="options"><header><h2 class="underline">Options</h2></header><div id="option-disabled" class="api-item first-item">
<h3>disabled<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>false</code>
</div>
<div>Disables the jQuery.Widget if set to <code>true</code>.</div>
<strong>Code examples:</strong><p>Initialize the jQuery.Widget with the disabled option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget({ disabled: </code><code class="keyword">true</code> <code class="plain">});</code></div></div></td></tr></tbody></table></div>
<p>Get or set the disabled option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">disabled = $( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"disabled"</code><code class="plain">, </code><code class="keyword">true</code> <code class="plain">);</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-hide" class="api-item">
<h3>hide<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>If and how to animate the hiding of the element.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>:
When set to <code>false</code>, no animation will be used and the element will be hidden immediately.
When set to <code>true</code>, the element will fade out with the default duration and the default easing.
</li>
<li>
<strong>Number</strong>:
The element will fade out with the specified duration and the default easing.
</li>
<li>
<strong>String</strong>:
The element will be hidden using the specified effect.
The value can either be the name of a built-in jQuery animateion method, such as <code>"slideUp"</code>, or the name of a jQuery UI effect, such as <code>"fold"</code>.
In either case the effect will be used with the default duration and the default easing.
</li>
<li>
<strong>Object</strong>: If the value is an object, then <code>effect</code>, <code>duration</code>, and <code>easing</code> properties may be provided. If the <code>effect</code> property contains the name of a jQuery method, then that method will be used; otherwise it is assumed to be the name of a jQuery UI effect. When using a jQuery UI effect that supports additional settings, you may include those settings in the object and they will be passed to the effect. If <code>duration</code> or <code>easing</code> is omitted, then the default values will be used. If <code>effect</code> is omitted, then <code>"fadeOut"</code> will be used.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the jQuery.Widget with the hide option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget({ hide: { effect: </code><code class="string">"explode"</code><code class="plain">, duration: 1000 } });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the hide option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">hide = $( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"hide"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"hide"</code><code class="plain">, { effect: </code><code class="string">"explode"</code><code class="plain">, duration: 1000 } );</code></div></div></td></tr></tbody></table></div>
</div>
<div id="option-show" class="api-item">
<h3>show<span class="option-type"><strong>Type: </strong><a href="http://api.jquery.com/Types#Boolean">Boolean</a> or <a href="http://api.jquery.com/Types#Number">Number</a> or <a href="http://api.jquery.com/Types#String">String</a> or <a href="http://api.jquery.com/Types#Object">Object</a></span>
</h3>
<div class="default">
<strong>Default: </strong><code>null</code>
</div>
<div>If and how to animate the showing of the element.</div>
<strong>Multiple types supported:</strong><ul>
<li>
<strong>Boolean</strong>:
When set to <code>false</code>, no animation will be used and the element will be shown immediately.
When set to <code>true</code>, the element will fade in with the default duration and the default easing.
</li>
<li>
<strong>Number</strong>:
The element will fade in with the specified duration and the default easing.
</li>
<li>
<strong>String</strong>:
The element will be shown using the specified effect.
The value can either be the name of a built-in jQuery animateion method, such as <code>"slideDown"</code>, or the name of a jQuery UI effect, such as <code>"fold"</code>.
In either case the effect will be used with the default duration and the default easing.
</li>
<li>
<strong>Object</strong>: If the value is an object, then <code>effect</code>, <code>duration</code>, and <code>easing</code> properties may be provided. If the <code>effect</code> property contains the name of a jQuery method, then that method will be used; otherwise it is assumed to be the name of a jQuery UI effect. When using a jQuery UI effect that supports additional settings, you may include those settings in the object and they will be passed to the effect. If <code>duration</code> or <code>easing</code> is omitted, then the default values will be used. If <code>effect</code> is omitted, then <code>"fadeIn"</code> will be used.</li>
</ul>
<strong>Code examples:</strong><p>Initialize the jQuery.Widget with the show option specified:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget({ show: { effect: </code><code class="string">"blind"</code><code class="plain">, duration: 800 } });</code></div></div></td></tr></tbody></table></div>
<p>Get or set the show option, after initialization:</p>
<div class="syntaxhighlighter nogutter "><table border="0" cellpadding="0" cellspacing="0"><tbody><tr><td class="code"><div class="container"><div class="line number1 index0 alt2"><code class="comments">// getter</code></div><div class="line number2 index1 alt1"><code class="keyword">var</code> <code class="plain">show = $( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"show"</code> <code class="plain">);</code></div><div class="line number3 index2 alt2"> </div><div class="line number4 index3 alt1"><code class="comments">// setter</code></div><div class="line number5 index4 alt2"><code class="plain">$( </code><code class="string">".selector"</code> <code class="plain">).jQuery.Widget( </code><code class="string">"option"</code><code class="plain">, </code><code class="string">"show"</code><code class="plain">, { effect: </code><code class="string">"blind"</code><code class="plain">, duration: 800 } );</code></div></div></td></tr></tbody></table></div>
</div></section><section id="methods"><header><h2 class="underline">Methods</h2></header><div id="method-_create"><div class="api-item first-item">
<h3>_create()</h3>
<div>
The <code>_create()</code> method is the widget's constructor.
There are no parameters, but <code>this.element</code> and <code>this.options</code> are already set.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_delay"><div class="api-item">
<h3>_delay( fn [, delay ] ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Number">Number</a></span>
</h3>
<div>
Invokes the provided function after a specified delay. Keeps <code>this</code> context correct. Essentially <code>setTimeout()</code>.
<p>Returns the timeout ID for use with <code>clearTimeout()</code>.</p>
</div>
<ul>
<li>
<div><strong>fn</strong></div>
<div>Type: <a href="http://api.jquery.com/Types/#Function">Function</a>() or <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The function to invoke. Can also be the name of a method on the widget.</div>
</li>
<li>
<div><strong>delay</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Number">Number</a>
</div>
<div>The number of milliseconds to wait before invoking the function. Deafults to <code>0</code>.</div>
</li>
</ul>
</div></div>
<div id="method-_destroy"><div class="api-item">
<h3>_destroy()</h3>
<div>
The public <a href="#method-destroy"><code>destroy()</code></a> method cleans up all common data, events, etc. and then delegates out to <code>_destroy()</code> for custom, widget-specific, cleanup.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_focusable"><div class="api-item">
<h3>_focusable( element )</h3>
<div>
Sets up <code>element</code> to apply the <code>ui-state-focus</code> class on focus.
<p>The event handlers are automatically cleaned up on destroy.</p>
</div>
<ul><li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The element(s) to apply the focusable behavior to.</div>
</li></ul>
</div></div>
<div id="method-_getCreateEventData"><div class="api-item">
<h3>_getCreateEventData() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>
All widgets trigger the <a href="#event-create"><code>create</code></a> event. By default, no data is provided in the event, but this method can return an object which will be passed as the <code>create</code> event's data.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_getCreateOptions"><div class="api-item">
<h3>_getCreateOptions() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>
This method allows the widget to define a custom method for defining options during instantiation. This user-provided options override the options returned by this method which override the default options.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_hide"><div class="api-item">
<h3>_hide( element, option [, callback ] )</h3>
<div>
Hides an element immediately, using built-in animation methods, or using custom effects.
See the <a href="#option-hide">hide</a> option for possible <code>option</code> values.
</div>
<ul>
<li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The element(s) to hide.</div>
</li>
<li>
<div><strong>option</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The settings defining how to hide the element.</div>
</li>
<li>
<div><strong>callback</strong></div>
<div>Type: <a href="http://api.jquery.com/Types/#Function">Function</a>()</div>
<div>Callback to invoke after the element has been fully hidden.</div>
</li>
</ul>
</div></div>
<div id="method-_hoverable"><div class="api-item">
<h3>_hoverable( element )</h3>
<div>
Sets up <code>element</code> to apply the <code>ui-state-hover</code> class on hover.
<p>The event handlers are automatically cleaned up on destroy.</p>
</div>
<ul><li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The element(s) to apply the hoverable behavior to.</div>
</li></ul>
</div></div>
<div id="method-_init"><div class="api-item">
<h3>_init()</h3>
<div>
Widgets have the concept of initialization that is distinct from creation. Any time the plugin is called with no arguments or with only an option hash, the widget is initialized; this includes when the widget is created.
<p><em>Note: Initialization should only be handled if there is a logical action to perform on successive calls to the widget with no arguments.</em></p>
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_off"><div class="api-item">
<h3>_off( element, eventName )</h3>
<div>
Unbinds event handlers from the specified element(s).
</div>
<ul>
<li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>
The element(s) to unbind the event handlers from. Unlike the <code>_on()</code> method, the elements are required for <code>_off()</code>.
</div>
</li>
<li>
<div><strong>eventName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>One or more space-separated event types.</div>
</li>
</ul>
</div></div>
<div id="method-_on"><div class="api-item">
<h3>_on( [element ], handlers )</h3>
<div>
Binds event handlers to the specified element(s). Delegation is supported via selectors inside the event names, e.g., "<code>click .foo</code>". The <code>_on()</code> method provides several benefits of direct event binding:
<ul>
<li>Maintains proper <code>this</code> context inside the handlers.</li>
<li>Automatically handles disabled widgets: If the widget is disabled or the event occurs on an element with the <code>ui-state-disabled</code> class, the event handler is not invoked.</li>
<li>Event handlers are automatically namespaced and cleaned up on destroy.</li>
</ul>
</div>
<ul>
<li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>Which element(s) to bind the event handlers to. If no element is provided, <code>this.element</code> is used.</div>
</li>
<li>
<div><strong>handlers</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>
A map in which the string keys represent the event type and optional selector for delegation, and the values represent a handler function to be called for the event.
</div>
</li>
</ul>
</div></div>
<div id="method-_setOption"><div class="api-item">
<h3>_setOption( key, value )</h3>
<div>
Called from the <a href="#method-_setOptions"><code>_setOptions()</code></a> method for each individual option. Widget state should be updated based on changes.
</div>
<ul>
<li>
<div><strong>key</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div></div>
<div id="method-_setOptions"><div class="api-item">
<h3>_setOptions( options )</h3>
<div>
Called whenever the <a href="#method-option"><code>option()</code></a> method is called, regardless of the form in which the <code>option()</code> method was called.
<p>Overriding this is useful if you can defer processor-intensive changes for multiple option changes.</p>
</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div></div>
<div id="method-_show"><div class="api-item">
<h3>_show( element, option [, callback ] )</h3>
<div>
Shows an element immediately, using built-in animation methods, or using custom effects.
See the <a href="#option-show">show</a> option for possible <code>option</code> values.
</div>
<ul>
<li>
<div><strong>element</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#jQuery">jQuery</a>
</div>
<div>The element(s) to show.</div>
</li>
<li>
<div><strong>option</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>The settings defining how to show the element.</div>
</li>
<li>
<div><strong>callback</strong></div>
<div>Type: <a href="http://api.jquery.com/Types/#Function">Function</a>()</div>
<div>Callback to invoke after the element has been fully shown.</div>
</li>
</ul>
</div></div>
<div id="method-_super"><div class="api-item">
<h3>_super()</h3>
<div>
Invokes the method of the same name from the parent widget, with any specified arguments. Essentially <code>.call()</code>.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-_superApply"><div class="api-item">
<h3>_superApply( arguments )</h3>
<div>
Invokes the method of the same name from the parent widget, with the array of arguments. Essentially <code>.apply()</code>.
</div>
<ul><li>
<div><strong>arguments</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Array">Array</a>
</div>
<div>Array of arguments to pass to the parent method.</div>
</li></ul>
</div></div>
<div id="method-_trigger"><div class="api-item">
<h3>_trigger( type [, event ] [, data ] )</h3>
<div>
Triggers an event and its associated callback.
<p>The option with the name equal to type is invoked as the callback.</p>
<p>The event name is the widget name + type.</p>
<p><em>Note: When providing data, you must provide all three parameters. If there is no event to pass along, just pass <code>null</code>.</em></p>
</div>
<ul>
<li>
<div><strong>type</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The <code>type</code> should match the name of a callback option. The full event type will be generated automatically.</div>
</li>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div>The original event that caused this event to occur; useful for providing context to the listener.</div>
</li>
<li>
<div><strong>data</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A hash of data associated with the event.</div>
</li>
</ul>
</div></div>
<div id="method-destroy"><div class="api-item">
<h3>destroy()</h3>
<div>
Removes the jQuery.Widget functionality completely. This will return the element back to its pre-init state.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-disable"><div class="api-item">
<h3>disable()</h3>
<div>
Disables the jQuery.Widget.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-enable"><div class="api-item">
<h3>enable()</h3>
<div>
Enables the jQuery.Widget.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div>
<div id="method-option">
<div class="api-item">
<h3>option( optionName ) <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#Object">Object</a></span>
</h3>
<div>Gets the value currently associated with the specified <code>optionName</code>.</div>
<ul><li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to get.</div>
</li></ul>
</div>
<div class="api-item">
<h3>option() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#PlainObject">PlainObject</a></span>
</h3>
<div>Gets an object containing key/value pairs representing the current jQuery.Widget options hash.</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div>
<div class="api-item">
<h3>option( optionName, value )</h3>
<div>Sets the value of the jQuery.Widget option associated with the specified <code>optionName</code>.</div>
<ul>
<li>
<div><strong>optionName</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#String">String</a>
</div>
<div>The name of the option to set.</div>
</li>
<li>
<div><strong>value</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A value to set for the option.</div>
</li>
</ul>
</div>
<div class="api-item">
<h3>option( options )</h3>
<div>Sets one or more options for the jQuery.Widget.</div>
<ul><li>
<div><strong>options</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div>A map of option-value pairs to set.</div>
</li></ul>
</div>
</div>
<div id="method-widget"><div class="api-item">
<h3>widget() <span class="returns">Returns: <a class="return" href="http://api.jquery.com/Types/#jQuery">jQuery</a></span>
</h3>
<div>
Returns a <code>jQuery</code> object containing the original element or other relevant generated element.
</div>
<ul><li><div class="null-signature">This method does not accept any arguments.</div></li></ul>
</div></div></section><section id="events"><header><h2 class="underline">Events</h2></header><div id="event-create" class="api-item first-item">
<h3>create( event, ui )</h3>
<div>
Triggered when the jQuery.Widget is created.
</div>
<ul>
<li>
<div><strong>event</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Event">Event</a>
</div>
<div></div>
</li>
<li>
<div><strong>ui</strong></div>
<div>Type: <a href="http://api.jquery.com/Types#Object">Object</a>
</div>
<div></div>
</li>
</ul>
</div></section>
</div></article>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/docs/jQuery.widget.html | HTML | bsd | 34,756 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Menu Demos</title>
</head>
<body>
<ul>
<li><a href="default.html">Default functionality</a></li>
<li><a href="icons.html">Icons</a></li>
</ul>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/menu/index.html | HTML | bsd | 245 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Menu - Icons</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.position.js"></script>
<script src="../../ui/jquery.ui.menu.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#menu" ).menu();
});
</script>
<style>
.ui-menu { width: 150px; }
</style>
</head>
<body>
<ul id="menu">
<li><a href="#"><span class="ui-icon ui-icon-disk"></span>Save</a></li>
<li><a href="#"><span class="ui-icon ui-icon-zoomin"></span>Zoom In</a></li>
<li><a href="#"><span class="ui-icon ui-icon-zoomout"></span>Zoom Out</a></li>
<li class="ui-state-disabled"><a href="#"><span class="ui-icon ui-icon-print"></span>Print...</a></li>
<li>
<a href="#">Playback</a>
<ul>
<li><a href="#"><span class="ui-icon ui-icon-seek-start"></span>Prev</a></li>
<li><a href="#"><span class="ui-icon ui-icon-stop"></span>Stop</a></li>
<li><a href="#"><span class="ui-icon ui-icon-play"></span>Play</a></li>
<li><a href="#"><span class="ui-icon ui-icon-seek-end"></span>Next</a></li>
</ul>
</li>
</ul>
<div class="demo-description">
<p>A menu with the default configuration, showing how to use a menu with icons.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/menu/icons.html | HTML | bsd | 1,465 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Menu - Default functionality</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.position.js"></script>
<script src="../../ui/jquery.ui.menu.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#menu" ).menu();
});
</script>
<style>
.ui-menu { width: 150px; }
</style>
</head>
<body>
<ul id="menu">
<li class="ui-state-disabled"><a href="#">Aberdeen</a></li>
<li><a href="#">Ada</a></li>
<li><a href="#">Adamsville</a></li>
<li><a href="#">Addyston</a></li>
<li>
<a href="#">Delphi</a>
<ul>
<li class="ui-state-disabled"><a href="#">Ada</a></li>
<li><a href="#">Saarland</a></li>
<li><a href="#">Salzburg</a></li>
</ul>
</li>
<li><a href="#">Saarland</a></li>
<li>
<a href="#">Salzburg</a>
<ul>
<li>
<a href="#">Delphi</a>
<ul>
<li><a href="#">Ada</a></li>
<li><a href="#">Saarland</a></li>
<li><a href="#">Salzburg</a></li>
</ul>
</li>
<li>
<a href="#">Delphi</a>
<ul>
<li><a href="#">Ada</a></li>
<li><a href="#">Saarland</a></li>
<li><a href="#">Salzburg</a></li>
</ul>
</li>
<li><a href="#">Perch</a></li>
</ul>
</li>
<li class="ui-state-disabled"><a href="#">Amesville</a></li>
</ul>
<div class="demo-description">
<p>A menu with the default configuration, disabled items and nested menus. A list is transformed, adding theming, mouse and keyboard navigation support. Try to tab to the menu then use the cursor keys to navigate.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/menu/default.html | HTML | bsd | 1,799 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Delay start</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable, #resizable2 { width: 150px; height: 150px; padding: 0.5em; }
#resizable h3, #resizable2 h3 { text-align: center; margin: 0; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
delay: 1000
});
$( "#resizable2" ).resizable({
distance: 40
});
});
</script>
</head>
<body>
<h3 class="docs">Time delay (ms):</h3>
<div id="resizable" class="ui-widget-content">
<h3 class="ui-widget-header">Time</h3>
</div>
<h3 class="docs">Distance delay (px):</h3>
<div id="resizable2" class="ui-widget-content">
<h3 class="ui-widget-header">Distance</h3>
</div>
<div class="demo-description">
<p>Delay the start of resizng for a number of milliseconds with the <code>delay</code> option; prevent resizing until the cursor is held down and dragged a specifed number of pixels with the <code>distance</code> option.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/delay-start.html | HTML | bsd | 1,372 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable Demos</title>
</head>
<body>
<ul>
<li><a href="default.html">Default functionality</a></li>
<li><a href="aspect-ratio.html">Preserve aspect ratio</a></li>
<li><a href="max-min.html">Maximum / minimum size</a></li>
<li><a href="constrain-area.html">Constrain resize area</a></li>
<li><a href="delay-start.html">Delay start</a></li>
<li><a href="snap-to-grid.html">Snap to grid</a></li>
<li><a href="visual-feedback.html">Visual feedback</a></li>
<li><a href="synchronous-resize.html">Synchronous resize</a></li>
<li><a href="animate.html">Animate</a></li>
<li><a href="helper.html">Resize Helper</a></li>
<li><a href="textarea.html">Textarea</a></li>
</ul>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/index.html | HTML | bsd | 777 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Textarea</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-resizable-se {
bottom: 17px;
}
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
handles: "se"
});
});
</script>
</head>
<body>
<textarea id="resizable" rows="5" cols="20"></textarea>
<div class="demo-description">
<p>Display only an outline of the element while resizing by setting the <code>helper</code> option to a CSS class.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/textarea.html | HTML | bsd | 888 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Snap to grid</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable { width: 150px; height: 150px; padding: 0.5em; }
#resizable h3 { text-align: center; margin: 0; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
grid: 50
});
});
</script>
</head>
<body>
<div id="resizable" class="ui-widget-content">
<h3 class="ui-widget-header">Grid</h3>
</div>
<div class="demo-description">
<p>Snap the resizable element to a grid. Set the dimensions of grid cells (height and width in pixels) with the <code>grid</code> option.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/snap-to-grid.html | HTML | bsd | 1,021 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Helper</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable { width: 150px; height: 150px; padding: 0.5em; }
#resizable h3 { text-align: center; margin: 0; }
.ui-resizable-helper { border: 2px dotted #00F; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
helper: "ui-resizable-helper"
});
});
</script>
</head>
<body>
<div id="resizable" class="ui-widget-content">
<h3 class="ui-widget-header">Helper</h3>
</div>
<div class="demo-description">
<p>Display only an outline of the element while resizing by setting the <code>helper</code> option to a CSS class.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/helper.html | HTML | bsd | 1,065 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Synchronous resize</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable { background-position: top left; }
#resizable, #also { width: 150px; height: 120px; padding: 0.5em; }
#resizable h3, #also h3 { text-align: center; margin: 0; }
#also { margin-top: 1em; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
alsoResize: "#also"
});
$( "#also" ).resizable();
});
</script>
</head>
<body>
<div id="resizable" class="ui-widget-header">
<h3 class="ui-state-active">Resize</h3>
</div>
<div id="also" class="ui-widget-content">
<h3 class="ui-widget-header">will also resize</h3>
</div>
<div class="demo-description">
<p>Resize multiple elements simultaneously by clicking and dragging the sides of one. Pass a shared selector into the <code>alsoResize</code> option.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/synchronous-resize.html | HTML | bsd | 1,272 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Default functionality</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable { width: 150px; height: 150px; padding: 0.5em; }
#resizable h3 { text-align: center; margin: 0; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable();
});
</script>
</head>
<body>
<div id="resizable" class="ui-widget-content">
<h3 class="ui-widget-header">Resizable</h3>
</div>
<div class="demo-description">
<p>Enable any DOM element to be resizable. With the cursor grab the right or bottom border and drag to the desired width or height.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/default.html | HTML | bsd | 1,012 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Visual feedback</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable { width: 150px; height: 150px; padding: 0.5em; }
#resizable h3 { text-align: center; margin: 0; }
.ui-resizable-ghost { border: 1px dotted gray; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
ghost: true
});
});
</script>
</head>
<body>
<div id="resizable" class="ui-widget-content">
<h3 class="ui-widget-header">Ghost</h3>
</div>
<div class="demo-description">
<p>Instead of showing the actual element during resize, set the <code>ghost</code> option to true to show a semi-transparent part of the element.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/visual-feedback.html | HTML | bsd | 1,085 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Animate</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable { width: 150px; height: 150px; padding: 0.5em; }
#resizable h3 { text-align: center; margin: 0; }
.ui-resizable-helper { border: 1px dotted gray; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
animate: true
});
});
</script>
</head>
<body>
<div id="resizable" class="ui-widget-content">
<h3 class="ui-widget-header">Animate</h3>
</div>
<div class="demo-description">
<p>Animate the resize action using the <code>animate</code> option (boolean). When this option is set to true, drag the outline to the desired location; the element animates to that size on drag stop.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/animate.html | HTML | bsd | 1,137 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Maximum / minimum size</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable { width: 200px; height: 150px; padding: 5px; }
#resizable h3 { text-align: center; margin: 0; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
maxHeight: 250,
maxWidth: 350,
minHeight: 150,
minWidth: 200
});
});
</script>
</head>
<body>
<div id="resizable" class="ui-widget-content">
<h3 class="ui-widget-header">Resize larger / smaller</h3>
</div>
<div class="demo-description">
<p>Limit the resizable element to a maximum or minimum height or width using the <code>maxHeight</code>, <code>maxWidth</code>, <code>minHeight</code>, and <code>minWidth</code> options.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/max-min.html | HTML | bsd | 1,157 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Preserve aspect ratio</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#resizable { width: 160px; height: 90px; padding: 0.5em; }
#resizable h3 { text-align: center; margin: 0; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
aspectRatio: 16 / 9
});
});
</script>
</head>
<body>
<div id="resizable" class="ui-widget-content">
<h3 class="ui-widget-header">Preserve aspect ratio</h3>
</div>
<div class="demo-description">
<p>Maintain the existing aspect ratio or set a new one to constrain the proportions on resize. Set the <code>aspectRatio</code> option to true, and optionally pass in a new ratio (i.e., 4/3)</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/aspect-ratio.html | HTML | bsd | 1,109 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Resizable - Constrain resize area</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.resizable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#container { width: 300px; height: 300px; }
#container h3 { text-align: center; margin: 0; margin-bottom: 10px; }
#resizable { background-position: top left; width: 150px; height: 150px; }
#resizable, #container { padding: 0.5em; }
</style>
<script>
$(function() {
$( "#resizable" ).resizable({
containment: "#container"
});
});
</script>
</head>
<body>
<div id="container" class="ui-widget-content">
<h3 class="ui-widget-header">Containment</h3>
<div id="resizable" class="ui-state-active">
<h3 class="ui-widget-header">Resizable</h3>
</div>
</div>
<div class="demo-description">
<p>Define the boundaries of the resizable area. Use the <code>containment</code> option to specify a parent DOM element or a jQuery selector, like 'document.'</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/resizable/constrain-area.html | HTML | bsd | 1,299 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Effects Demos</title>
</head>
<body>
<ul>
<li><a href="default.html">Effect showcase</a></li>
<li><a href="easing.html">Easing showcase</a></li>
</ul>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/effect/index.html | HTML | bsd | 253 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Effects - Easing demo</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.effect.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.graph {
float: left;
margin-left: 10px;
}
</style>
<script>
$(function() {
if ( !$( "<canvas>" )[0].getContext ) {
$( "<div>" ).text(
"Your browser doesn't support canvas, which is required for this demo."
).appendTo( "#graphs" );
return;
}
var i = 0,
width = 100,
height = 100;
$.each( $.easing, function( name, impl ) {
var graph = $( "<div>" ).addClass( "graph" ).appendTo( "#graphs" ),
text = $( "<div>" ).text( ++i + ". " + name ).appendTo( graph ),
wrap = $( "<div>" ).appendTo( graph ).css( 'overflow', 'hidden' ),
canvas = $( "<canvas>" ).appendTo( wrap )[ 0 ];
canvas.width = width;
canvas.height = height;
var drawHeight = height * 0.8,
cradius = 10;
ctx = canvas.getContext( "2d" );
ctx.fillStyle = "black";
// draw background
ctx.beginPath();
ctx.moveTo( cradius, 0 );
ctx.quadraticCurveTo( 0, 0, 0, cradius );
ctx.lineTo( 0, height - cradius );
ctx.quadraticCurveTo( 0, height, cradius, height );
ctx.lineTo( width - cradius, height );
ctx.quadraticCurveTo( width, height, width, height - cradius );
ctx.lineTo( width, 0 );
ctx.lineTo( cradius, 0 );
ctx.fill();
// draw bottom line
ctx.strokeStyle = "#555";
ctx.beginPath();
ctx.moveTo( width * 0.1, drawHeight + .5 );
ctx.lineTo( width * 0.9, drawHeight + .5 );
ctx.stroke();
// draw top line
ctx.strokeStyle = "#555";
ctx.beginPath();
ctx.moveTo( width * 0.1, drawHeight * .3 - .5 );
ctx.lineTo( width * 0.9, drawHeight * .3 - .5 );
ctx.stroke();
// plot easing
ctx.strokeStyle = "white";
ctx.beginPath();
ctx.lineWidth = 2;
ctx.moveTo( width * 0.1, drawHeight );
$.each( new Array( width ), function( position ) {
var state = position / width,
val = impl( state, position, 0, 1, width );
ctx.lineTo( position * 0.8 + width * 0.1,
drawHeight - drawHeight * val * 0.7 );
});
ctx.stroke();
// animate on click
graph.click(function() {
wrap
.animate( { height: "hide" }, 2000, name )
.delay( 800 )
.animate( { height: "show" }, 2000, name );
});
graph.width( width ).height( height + text.height() + 10 );
});
});
</script>
</head>
<body>
<div id="graphs"></div>
<div class="demo-description">
<p><strong>All easings provided by jQuery UI are drawn above, using a HTML canvas element</strong>. Click a diagram to see the easing in action.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/effect/easing.html | HTML | bsd | 2,792 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Effects - Effect demo</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.effect.js"></script>
<script src="../../ui/jquery.ui.effect-blind.js"></script>
<script src="../../ui/jquery.ui.effect-bounce.js"></script>
<script src="../../ui/jquery.ui.effect-clip.js"></script>
<script src="../../ui/jquery.ui.effect-drop.js"></script>
<script src="../../ui/jquery.ui.effect-explode.js"></script>
<script src="../../ui/jquery.ui.effect-fade.js"></script>
<script src="../../ui/jquery.ui.effect-fold.js"></script>
<script src="../../ui/jquery.ui.effect-highlight.js"></script>
<script src="../../ui/jquery.ui.effect-pulsate.js"></script>
<script src="../../ui/jquery.ui.effect-scale.js"></script>
<script src="../../ui/jquery.ui.effect-shake.js"></script>
<script src="../../ui/jquery.ui.effect-slide.js"></script>
<script src="../../ui/jquery.ui.effect-transfer.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.toggler { width: 500px; height: 200px; position: relative; }
#button { padding: .5em 1em; text-decoration: none; }
#effect { width: 240px; height: 135px; padding: 0.4em; position: relative; }
#effect h3 { margin: 0; padding: 0.4em; text-align: center; }
.ui-effects-transfer { border: 2px dotted gray; }
</style>
<script>
$(function() {
// run the currently selected effect
function runEffect() {
// get effect type from
var selectedEffect = $( "#effectTypes" ).val();
// most effect types need no options passed by default
var options = {};
// some effects have required parameters
if ( selectedEffect === "scale" ) {
options = { percent: 0 };
} else if ( selectedEffect === "transfer" ) {
options = { to: "#button", className: "ui-effects-transfer" };
} else if ( selectedEffect === "size" ) {
options = { to: { width: 200, height: 60 } };
}
// run the effect
$( "#effect" ).effect( selectedEffect, options, 500, callback );
};
// callback function to bring a hidden box back
function callback() {
setTimeout(function() {
$( "#effect" ).removeAttr( "style" ).hide().fadeIn();
}, 1000 );
};
// set effect from select menu value
$( "#button" ).click(function() {
runEffect();
return false;
});
});
</script>
</head>
<body>
<div class="toggler">
<div id="effect" class="ui-widget-content ui-corner-all">
<h3 class="ui-widget-header ui-corner-all">Effect</h3>
<p>
Etiam libero neque, luctus a, eleifend nec, semper at, lorem. Sed pede. Nulla lorem metus, adipiscing ut, luctus sed, hendrerit vitae, mi.
</p>
</div>
</div>
<select name="effects" id="effectTypes">
<option value="blind">Blind</option>
<option value="bounce">Bounce</option>
<option value="clip">Clip</option>
<option value="drop">Drop</option>
<option value="explode">Explode</option>
<option value="fade">Fade</option>
<option value="fold">Fold</option>
<option value="highlight">Highlight</option>
<option value="puff">Puff</option>
<option value="pulsate">Pulsate</option>
<option value="scale">Scale</option>
<option value="shake">Shake</option>
<option value="size">Size</option>
<option value="slide">Slide</option>
<option value="transfer">Transfer</option>
</select>
<a href="#" id="button" class="ui-state-default ui-corner-all">Run Effect</a>
<div class="demo-description">
<p>Click the button above to show the effect.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/effect/default.html | HTML | bsd | 3,572 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Snap to increments</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#slider" ).slider({
value:100,
min: 0,
max: 500,
step: 50,
slide: function( event, ui ) {
$( "#amount" ).val( "$" + ui.value );
}
});
$( "#amount" ).val( "$" + $( "#slider" ).slider( "value" ) );
});
</script>
</head>
<body>
<p>
<label for="amount">Donation amount ($50 increments):</label>
<input type="text" id="amount" style="border:0; color:#f6931f; font-weight:bold;" />
</p>
<div id="slider"></div>
<div class="demo-description">
<p>Increment slider values with the <code>step</code> option set to an integer, commonly a dividend of the slider's maximum value. The default increment is 1.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/steps.html | HTML | bsd | 1,179 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Range with fixed minimum</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#slider-range-min" ).slider({
range: "min",
value: 37,
min: 1,
max: 700,
slide: function( event, ui ) {
$( "#amount" ).val( "$" + ui.value );
}
});
$( "#amount" ).val( "$" + $( "#slider-range-min" ).slider( "value" ) );
});
</script>
</head>
<body>
<p>
<label for="amount">Maximum price:</label>
<input type="text" id="amount" style="border:0; color:#f6931f; font-weight:bold;" />
</p>
<div id="slider-range-min"></div>
<div class="demo-description">
<p>Fix the minimum value of the range slider so that the user can only select a maximum. Set the <code>range</code> option to "min."</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/rangemin.html | HTML | bsd | 1,174 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider Demos</title>
</head>
<body>
<ul>
<li><a href="default.html">Default functionality</a></li>
<li><a href="steps.html">Snap to increments</a></li>
<li><a href="range.html">Range slider</a></li>
<li><a href="rangemin.html">Range with fixed minimum</a></li>
<li><a href="hotelrooms.html">Room reservation</a></li>
<li><a href="rangemax.html">Range with fixed maximum</a></li>
<li><a href="slider-vertical.html">Vertical slider</a></li>
<li><a href="range-vertical.html">Vertical range slider</a></li>
<li><a href="multiple-vertical.html">Multiple sliders</a></li>
<li><a href="colorpicker.html">Simple colorpicker</a></li>
<li><a href="side-scroll.html">Simple scrollbar</a></li>
</ul>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/index.html | HTML | bsd | 800 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Multiple sliders</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#eq span {
height:120px; float:left; margin:15px
}
</style>
<script>
$(function() {
// setup master volume
$( "#master" ).slider({
value: 60,
orientation: "horizontal",
range: "min",
animate: true
});
// setup graphic EQ
$( "#eq > span" ).each(function() {
// read initial values from markup and remove that
var value = parseInt( $( this ).text(), 10 );
$( this ).empty().slider({
value: value,
range: "min",
animate: true,
orientation: "vertical"
});
});
});
</script>
</head>
<body>
<p class="ui-state-default ui-corner-all ui-helper-clearfix" style="padding:4px;">
<span class="ui-icon ui-icon-volume-on" style="float:left; margin:-2px 5px 0 0;"></span>
Master volume
</p>
<div id="master" style="width:260px; margin:15px;"></div>
<p class="ui-state-default ui-corner-all" style="padding:4px;margin-top:4em;">
<span class="ui-icon ui-icon-signal" style="float:left; margin:-2px 5px 0 0;"></span>
Graphic EQ
</p>
<div id="eq">
<span>88</span>
<span>77</span>
<span>55</span>
<span>33</span>
<span>40</span>
<span>45</span>
<span>70</span>
</div>
<div class="demo-description">
<p>Combine horizontal and vertical sliders, each with their own options, to create the UI for a music player.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/multiple-vertical.html | HTML | bsd | 1,791 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Colorpicker</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#red, #green, #blue {
float: left;
clear: left;
width: 300px;
margin: 15px;
}
#swatch {
width: 120px;
height: 100px;
margin-top: 18px;
margin-left: 350px;
background-image: none;
}
#red .ui-slider-range { background: #ef2929; }
#red .ui-slider-handle { border-color: #ef2929; }
#green .ui-slider-range { background: #8ae234; }
#green .ui-slider-handle { border-color: #8ae234; }
#blue .ui-slider-range { background: #729fcf; }
#blue .ui-slider-handle { border-color: #729fcf; }
</style>
<script>
function hexFromRGB(r, g, b) {
var hex = [
r.toString( 16 ),
g.toString( 16 ),
b.toString( 16 )
];
$.each( hex, function( nr, val ) {
if ( val.length === 1 ) {
hex[ nr ] = "0" + val;
}
});
return hex.join( "" ).toUpperCase();
}
function refreshSwatch() {
var red = $( "#red" ).slider( "value" ),
green = $( "#green" ).slider( "value" ),
blue = $( "#blue" ).slider( "value" ),
hex = hexFromRGB( red, green, blue );
$( "#swatch" ).css( "background-color", "#" + hex );
}
$(function() {
$( "#red, #green, #blue" ).slider({
orientation: "horizontal",
range: "min",
max: 255,
value: 127,
slide: refreshSwatch,
change: refreshSwatch
});
$( "#red" ).slider( "value", 255 );
$( "#green" ).slider( "value", 140 );
$( "#blue" ).slider( "value", 60 );
});
</script>
</head>
<body class="ui-widget-content" style="border:0;">
<p class="ui-state-default ui-corner-all ui-helper-clearfix" style="padding:4px;">
<span class="ui-icon ui-icon-pencil" style="float:left; margin:-2px 5px 0 0;"></span>
Simple Colorpicker
</p>
<div id="red"></div>
<div id="green"></div>
<div id="blue"></div>
<div id="swatch" class="ui-widget-content ui-corner-all"></div>
<div class="demo-description">
<p>Combine three sliders to create a simple RGB colorpicker.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/colorpicker.html | HTML | bsd | 2,358 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Range slider</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#slider-range" ).slider({
range: true,
min: 0,
max: 500,
values: [ 75, 300 ],
slide: function( event, ui ) {
$( "#amount" ).val( "$" + ui.values[ 0 ] + " - $" + ui.values[ 1 ] );
}
});
$( "#amount" ).val( "$" + $( "#slider-range" ).slider( "values", 0 ) +
" - $" + $( "#slider-range" ).slider( "values", 1 ) );
});
</script>
</head>
<body>
<p>
<label for="amount">Price range:</label>
<input type="text" id="amount" style="border:0; color:#f6931f; font-weight:bold;" />
</p>
<div id="slider-range"></div>
<div class="demo-description">
<p>Set the <code>range</code> option to true to capture a range of values with two drag handles. The space between the handles is filled with a different background color to indicate those values are selected.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/range.html | HTML | bsd | 1,327 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" >
<title>jQuery UI Slider - Default functionality</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#slider" ).slider();
});
</script>
</head>
<body>
<div id="slider"></div>
<div class="demo-description">
<p>The basic slider is horizontal and has a single handle that can be moved with the mouse or by using the arrow keys.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/default.html | HTML | bsd | 782 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Vertical slider</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#slider-vertical" ).slider({
orientation: "vertical",
range: "min",
min: 0,
max: 100,
value: 60,
slide: function( event, ui ) {
$( "#amount" ).val( ui.value );
}
});
$( "#amount" ).val( $( "#slider-vertical" ).slider( "value" ) );
});
</script>
</head>
<body>
<p>
<label for="amount">Volume:</label>
<input type="text" id="amount" style="border:0; color:#f6931f; font-weight:bold;" />
</p>
<div id="slider-vertical" style="height:200px;"></div>
<div class="demo-description">
<p>Change the orientation of the slider to vertical. Assign a height value via <code>.height()</code> or by setting the height through CSS, and set the <code>orientation</code> option to "vertical."</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/slider-vertical.html | HTML | bsd | 1,259 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Slider scrollbar</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.scroll-pane { overflow: auto; width: 99%; float:left; }
.scroll-content { width: 2440px; float: left; }
.scroll-content-item { width: 100px; height: 100px; float: left; margin: 10px; font-size: 3em; line-height: 96px; text-align: center; }
* html .scroll-content-item { display: inline; } /* IE6 float double margin bug */
.scroll-bar-wrap { clear: left; padding: 0 4px 0 2px; margin: 0 -1px -1px -1px; }
.scroll-bar-wrap .ui-slider { background: none; border:0; height: 2em; margin: 0 auto; }
.scroll-bar-wrap .ui-handle-helper-parent { position: relative; width: 100%; height: 100%; margin: 0 auto; }
.scroll-bar-wrap .ui-slider-handle { top:.2em; height: 1.5em; }
.scroll-bar-wrap .ui-slider-handle .ui-icon { margin: -8px auto 0; position: relative; top: 50%; }
</style>
<script>
$(function() {
//scrollpane parts
var scrollPane = $( ".scroll-pane" ),
scrollContent = $( ".scroll-content" );
//build slider
var scrollbar = $( ".scroll-bar" ).slider({
slide: function( event, ui ) {
if ( scrollContent.width() > scrollPane.width() ) {
scrollContent.css( "margin-left", Math.round(
ui.value / 100 * ( scrollPane.width() - scrollContent.width() )
) + "px" );
} else {
scrollContent.css( "margin-left", 0 );
}
}
});
//append icon to handle
var handleHelper = scrollbar.find( ".ui-slider-handle" )
.mousedown(function() {
scrollbar.width( handleHelper.width() );
})
.mouseup(function() {
scrollbar.width( "100%" );
})
.append( "<span class='ui-icon ui-icon-grip-dotted-vertical'></span>" )
.wrap( "<div class='ui-handle-helper-parent'></div>" ).parent();
//change overflow to hidden now that slider handles the scrolling
scrollPane.css( "overflow", "hidden" );
//size scrollbar and handle proportionally to scroll distance
function sizeScrollbar() {
var remainder = scrollContent.width() - scrollPane.width();
var proportion = remainder / scrollContent.width();
var handleSize = scrollPane.width() - ( proportion * scrollPane.width() );
scrollbar.find( ".ui-slider-handle" ).css({
width: handleSize,
"margin-left": -handleSize / 2
});
handleHelper.width( "" ).width( scrollbar.width() - handleSize );
}
//reset slider value based on scroll content position
function resetValue() {
var remainder = scrollPane.width() - scrollContent.width();
var leftVal = scrollContent.css( "margin-left" ) === "auto" ? 0 :
parseInt( scrollContent.css( "margin-left" ) );
var percentage = Math.round( leftVal / remainder * 100 );
scrollbar.slider( "value", percentage );
}
//if the slider is 100% and window gets larger, reveal content
function reflowContent() {
var showing = scrollContent.width() + parseInt( scrollContent.css( "margin-left" ), 10 );
var gap = scrollPane.width() - showing;
if ( gap > 0 ) {
scrollContent.css( "margin-left", parseInt( scrollContent.css( "margin-left" ), 10 ) + gap );
}
}
//change handle position on window resize
$( window ).resize(function() {
resetValue();
sizeScrollbar();
reflowContent();
});
//init scrollbar size
setTimeout( sizeScrollbar, 10 );//safari wants a timeout
});
</script>
</head>
<body>
<div class="scroll-pane ui-widget ui-widget-header ui-corner-all">
<div class="scroll-content">
<div class="scroll-content-item ui-widget-header">1</div>
<div class="scroll-content-item ui-widget-header">2</div>
<div class="scroll-content-item ui-widget-header">3</div>
<div class="scroll-content-item ui-widget-header">4</div>
<div class="scroll-content-item ui-widget-header">5</div>
<div class="scroll-content-item ui-widget-header">6</div>
<div class="scroll-content-item ui-widget-header">7</div>
<div class="scroll-content-item ui-widget-header">8</div>
<div class="scroll-content-item ui-widget-header">9</div>
<div class="scroll-content-item ui-widget-header">10</div>
<div class="scroll-content-item ui-widget-header">11</div>
<div class="scroll-content-item ui-widget-header">12</div>
<div class="scroll-content-item ui-widget-header">13</div>
<div class="scroll-content-item ui-widget-header">14</div>
<div class="scroll-content-item ui-widget-header">15</div>
<div class="scroll-content-item ui-widget-header">16</div>
<div class="scroll-content-item ui-widget-header">17</div>
<div class="scroll-content-item ui-widget-header">18</div>
<div class="scroll-content-item ui-widget-header">19</div>
<div class="scroll-content-item ui-widget-header">20</div>
</div>
<div class="scroll-bar-wrap ui-widget-content ui-corner-bottom">
<div class="scroll-bar"></div>
</div>
</div>
<div class="demo-description">
<p>Use a slider to manipulate the positioning of content on the page. In this case, it acts as a scrollbar with the potential to capture values if needed.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/side-scroll.html | HTML | bsd | 5,382 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Range with fixed maximum</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#slider-range-max" ).slider({
range: "max",
min: 1,
max: 10,
value: 2,
slide: function( event, ui ) {
$( "#amount" ).val( ui.value );
}
});
$( "#amount" ).val( $( "#slider-range-max" ).slider( "value" ) );
});
</script>
</head>
<body>
<p>
<label for="amount">Minimum number of bedrooms:</label>
<input type="text" id="amount" style="border:0; color:#f6931f; font-weight:bold;" />
</p>
<div id="slider-range-max"></div>
<div class="demo-description">
<p>Fix the maximum value of the range slider so that the user can only select a minimum. Set the <code>range</code> option to "max."</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/rangemax.html | HTML | bsd | 1,172 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Slider bound to select</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
var select = $( "#minbeds" );
var slider = $( "<div id='slider'></div>" ).insertAfter( select ).slider({
min: 1,
max: 6,
range: "min",
value: select[ 0 ].selectedIndex + 1,
slide: function( event, ui ) {
select[ 0 ].selectedIndex = ui.value - 1;
}
});
$( "#minbeds" ).change(function() {
slider.slider( "value", this.selectedIndex + 1 );
});
});
</script>
</head>
<body>
<form id="reservation">
<label for="minbeds">Minimum number of beds</label>
<select name="minbeds" id="minbeds">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
<option>6</option>
</select>
</form>
<div class="demo-description">
<p>How to bind a slider to an existing select element. The select stays visible to display the change. When the select is changed, the slider is updated, too.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/hotelrooms.html | HTML | bsd | 1,408 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Slider - Vertical range slider</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.slider.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#slider-range" ).slider({
orientation: "vertical",
range: true,
values: [ 17, 67 ],
slide: function( event, ui ) {
$( "#amount" ).val( "$" + ui.values[ 0 ] + " - $" + ui.values[ 1 ] );
}
});
$( "#amount" ).val( "$" + $( "#slider-range" ).slider( "values", 0 ) +
" - $" + $( "#slider-range" ).slider( "values", 1 ) );
});
</script>
</head>
<body>
<p>
<label for="amount">Target sales goal (Millions):</label>
<input type="text" id="amount" style="border:0; color:#f6931f; font-weight:bold;" />
</p>
<div id="slider-range" style="height:250px;"></div>
<div class="demo-description">
<p>Change the orientation of the range slider to vertical. Assign a height value via <code>.height()</code> or by setting the height through CSS, and set the <code>orientation</code> option to "vertical."</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/slider/range-vertical.html | HTML | bsd | 1,373 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Delay start</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#draggable, #draggable2 { width: 120px; height: 120px; padding: 0.5em; float: left; margin: 0 10px 10px 0; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable({ distance: 20 });
$( "#draggable2" ).draggable({ delay: 1000 });
$( ".ui-draggable" ).disableSelection();
});
</script>
</head>
<body>
<div id="draggable" class="ui-widget-content">
<p>Only if you drag me by 20 pixels, the dragging will start</p>
</div>
<div id="draggable2" class="ui-widget-content">
<p>Regardless of the distance, you have to drag and wait for 1000ms before dragging starts</p>
</div>
<div class="demo-description">
<p>Delay the start of dragging for a number of milliseconds with the <code>delay</code> option; prevent dragging until the cursor is held down and dragged a specifed number of pixels with the <code>distance</code> option. </p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/delay-start.html | HTML | bsd | 1,372 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable Demos</title>
</head>
<body>
<ul>
<li><a href="default.html">Default functionality</a></li>
<li><a href="events.html">Events</a></li>
<li><a href="constrain-movement.html">Constrain movement</a></li>
<li><a href="delay-start.html">Delay start</a></li>
<li><a href="snap-to.html">Snap to element or grid</a></li>
<li><a href="scroll.html">Auto-scroll</a></li>
<li><a href="revert.html">Revert position</a></li>
<li><a href="visual-feedback.html">Visual feedback</a></li>
<li><a href="handle.html">Drag handle</a></li>
<li><a href="cursor-style.html">Cursor style</a></li>
<li><a href="sortable.html">Draggable + Sortable</a></li>
</ul>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/index.html | HTML | bsd | 756 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Events</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#draggable { width: 16em; padding: 0 1em; }
#draggable ul li { margin: 1em 0; padding: 0.5em 0; } * html #draggable ul li { height: 1%; }
#draggable ul li span.ui-icon { float: left; }
#draggable ul li span.count { font-weight: bold; }
</style>
<script>
$(function() {
var $start_counter = $( "#event-start" ),
$drag_counter = $( "#event-drag" ),
$stop_counter = $( "#event-stop" ),
counts = [ 0, 0, 0 ];
$( "#draggable" ).draggable({
start: function() {
counts[ 0 ]++;
updateCounterStatus( $start_counter, counts[ 0 ] );
},
drag: function() {
counts[ 1 ]++;
updateCounterStatus( $drag_counter, counts[ 1 ] );
},
stop: function() {
counts[ 2 ]++;
updateCounterStatus( $stop_counter, counts[ 2 ] );
}
});
function updateCounterStatus( $event_counter, new_count ) {
// first update the status visually...
if ( !$event_counter.hasClass( "ui-state-hover" ) ) {
$event_counter.addClass( "ui-state-hover" )
.siblings().removeClass( "ui-state-hover" );
}
// ...then update the numbers
$( "span.count", $event_counter ).text( new_count );
}
});
</script>
</head>
<body>
<div id="draggable" class="ui-widget ui-widget-content">
<p>Drag me to trigger the chain of events.</p>
<ul class="ui-helper-reset">
<li id="event-start" class="ui-state-default ui-corner-all"><span class="ui-icon ui-icon-play"></span>"start" invoked <span class="count">0</span>x</li>
<li id="event-drag" class="ui-state-default ui-corner-all"><span class="ui-icon ui-icon-arrow-4"></span>"drag" invoked <span class="count">0</span>x</li>
<li id="event-stop" class="ui-state-default ui-corner-all"><span class="ui-icon ui-icon-stop"></span>"stop" invoked <span class="count">0</span>x</li>
</ul>
</div>
<div class="demo-description">
<p>Layer functionality onto the draggable using the <code>start</code>, <code>drag</code>, and <code>stop</code> events. Start is fired at the start of the drag; drag during the drag; and stop when dragging stops.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/events.html | HTML | bsd | 2,542 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Constrain movement</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.draggable { width: 90px; height: 90px; padding: 0.5em; float: left; margin: 0 10px 10px 0; }
#draggable, #draggable2 { margin-bottom:20px; }
#draggable { cursor: n-resize; }
#draggable2 { cursor: e-resize; }
#containment-wrapper { width: 95%; height:150px; border:2px solid #ccc; padding: 10px; }
h3 { clear: left; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable({ axis: "y" });
$( "#draggable2" ).draggable({ axis: "x" });
$( "#draggable3" ).draggable({ containment: "#containment-wrapper", scroll: false });
$( "#draggable5" ).draggable({ containment: "parent" });
});
</script>
</head>
<body>
<h3>Constrain movement along an axis:</h3>
<div id="draggable" class="draggable ui-widget-content">
<p>I can be dragged only vertically</p>
</div>
<div id="draggable2" class="draggable ui-widget-content">
<p>I can be dragged only horizontally</p>
</div>
<h3>Or to within another DOM element:</h3>
<div id="containment-wrapper">
<div id="draggable3" class="draggable ui-widget-content">
<p>I'm contained within the box</p>
</div>
<div class="draggable ui-widget-content">
<p id="draggable5" class="ui-widget-header">I'm contained within my parent</p>
</div>
</div>
<div class="demo-description">
<p>Constrain the movement of each draggable by defining the boundaries of the draggable area. Set the <code>axis</code> option to limit the draggable's path to the x- or y-axis, or use the <code>containment</code> option to specify a parent DOM element or a jQuery selector, like 'document.'</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/constrain-movement.html | HTML | bsd | 2,068 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Cursor style</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#draggable, #draggable2, #draggable3 { width: 100px; height: 100px; padding: 0.5em; float: left; margin: 0 10px 10px 0; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable({ cursor: "move", cursorAt: { top: 56, left: 56 } });
$( "#draggable2" ).draggable({ cursor: "crosshair", cursorAt: { top: -5, left: -5 } });
$( "#draggable3" ).draggable({ cursorAt: { bottom: 0 } });
});
</script>
</head>
<body>
<div id="draggable" class="ui-widget-content">
<p>I will always stick to the center (relative to the mouse)</p>
</div>
<div id="draggable2" class="ui-widget-content">
<p>My cursor is at left -5 and top -5</p>
</div>
<div id="draggable3" class="ui-widget-content">
<p>My cursor position is only controlled for the 'bottom' value</p>
</div>
<div class="demo-description">
<p>Position the cursor while dragging the object. By default the cursor appears in the center of the dragged object; use the <code>cursorAt</code> option to specify another location relative to the draggable (specify a pixel value from the top, right, bottom, and/or left). Customize the cursor's appearance by supplying the <code>cursor</code> option with a valid CSS cursor value: default, move, pointer, crosshair, etc.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/cursor-style.html | HTML | bsd | 1,753 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Snap to element or grid</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.draggable { width: 90px; height: 80px; padding: 5px; float: left; margin: 0 10px 10px 0; font-size: .9em; }
.ui-widget-header p, .ui-widget-content p { margin: 0; }
#snaptarget { height: 140px; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable({ snap: true });
$( "#draggable2" ).draggable({ snap: ".ui-widget-header" });
$( "#draggable3" ).draggable({ snap: ".ui-widget-header", snapMode: "outer" });
$( "#draggable4" ).draggable({ grid: [ 20,20 ] });
$( "#draggable5" ).draggable({ grid: [ 80, 80 ] });
});
</script>
</head>
<body>
<div id="snaptarget" class="ui-widget-header">
<p>I'm a snap target</p>
</div>
<br style="clear:both" />
<div id="draggable" class="draggable ui-widget-content">
<p>Default (snap: true), snaps to all other draggable elements</p>
</div>
<div id="draggable2" class="draggable ui-widget-content">
<p>I only snap to the big box</p>
</div>
<div id="draggable3" class="draggable ui-widget-content">
<p>I only snap to the outer edges of the big box</p>
</div>
<div id="draggable4" class="draggable ui-widget-content">
<p>I snap to a 20 x 20 grid</p>
</div>
<div id="draggable5" class="draggable ui-widget-content">
<p>I snap to a 80 x 80 grid</p>
</div>
<div class="demo-description">
<p>Snap the draggable to the inner or outer boundaries of a DOM element. Use the <code>snap</code>, <code>snapMode</code> (inner, outer, both), and <code>snapTolerance</code> (distance in pixels the draggable must be from the element when snapping is invoked) options. </p>
<p>Or snap the draggable to a grid. Set the dimensions of grid cells (height and width in pixels) with the <code>grid</code> option.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/snap-to.html | HTML | bsd | 2,205 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Default functionality</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#draggable { width: 150px; height: 150px; padding: 0.5em; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable();
});
</script>
</head>
<body>
<div id="draggable" class="ui-widget-content">
<p>Drag me around</p>
</div>
<div class="demo-description">
<p>Enable draggable functionality on any DOM element. Move the draggable object by clicking on it with the mouse and dragging it anywhere within the viewport.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/default.html | HTML | bsd | 966 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Revert position</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#draggable, #draggable2 { width: 100px; height: 100px; padding: 0.5em; float: left; margin: 0 10px 10px 0; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable({ revert: true });
$( "#draggable2" ).draggable({ revert: true, helper: "clone" });
});
</script>
</head>
<body>
<div id="draggable" class="ui-widget-content">
<p>Revert the original</p>
</div>
<div id="draggable2" class="ui-widget-content">
<p>Revert the helper</p>
</div>
<div class="demo-description">
<p>Return the draggable (or it's helper) to its original location when dragging stops with the boolean <code>revert</code> option.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/revert.html | HTML | bsd | 1,151 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Handles</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#draggable, #draggable2 { width: 100px; height: 100px; padding: 0.5em; float: left; margin: 0 10px 10px 0; }
#draggable p { cursor: move; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable({ handle: "p" });
$( "#draggable2" ).draggable({ cancel: "p.ui-widget-header" });
$( "div, p" ).disableSelection();
});
</script>
</head>
<body>
<div id="draggable" class="ui-widget-content">
<p class="ui-widget-header">I can be dragged only by this handle</p>
</div>
<div id="draggable2" class="ui-widget-content">
<p>You can drag me around…</p>
<p class="ui-widget-header">…but you can't drag me by this handle.</p>
</div>
<div class="demo-description">
<p>Allow dragging only when the cursor is over a specific part of the draggable. Use the <code>handle</code> option to specify the jQuery selector of an element (or group of elements) used to drag the object.</p>
<p>Or prevent dragging when the cursor is over a specific element (or group of elements) within the draggable. Use the <code>cancel</code> option to specify a jQuery selector over which to "cancel" draggable functionality.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/handle.html | HTML | bsd | 1,650 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable + Sortable</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<script src="../../ui/jquery.ui.sortable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
ul { list-style-type: none; margin: 0; padding: 0; margin-bottom: 10px; }
li { margin: 5px; padding: 5px; width: 150px; }
</style>
<script>
$(function() {
$( "#sortable" ).sortable({
revert: true
});
$( "#draggable" ).draggable({
connectToSortable: "#sortable",
helper: "clone",
revert: "invalid"
});
$( "ul, li" ).disableSelection();
});
</script>
</head>
<body>
<ul>
<li id="draggable" class="ui-state-highlight">Drag me down</li>
</ul>
<ul id="sortable">
<li class="ui-state-default">Item 1</li>
<li class="ui-state-default">Item 2</li>
<li class="ui-state-default">Item 3</li>
<li class="ui-state-default">Item 4</li>
<li class="ui-state-default">Item 5</li>
</ul>
<div class="demo-description">
<p>Draggables are built to interact seamlessly with <a href="http://jqueryui.com/sortable">sortables</a>.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/sortable.html | HTML | bsd | 1,423 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Visual feedback</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#draggable, #draggable2, #draggable3, #set div { width: 90px; height: 90px; padding: 0.5em; float: left; margin: 0 10px 10px 0; }
#draggable, #draggable2, #draggable3 { margin-bottom:20px; }
#set { clear:both; float:left; width: 368px; height: 120px; }
p { clear:both; margin:0; padding:1em 0; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable({ helper: "original" });
$( "#draggable2" ).draggable({ opacity: 0.7, helper: "clone" });
$( "#draggable3" ).draggable({
cursor: "move",
cursorAt: { top: -12, left: -20 },
helper: function( event ) {
return $( "<div class='ui-widget-header'>I'm a custom helper</div>" );
}
});
$( "#set div" ).draggable({ stack: "#set div" });
});
</script>
</head>
<body>
<h3 class="docs">With helpers:</h3>
<div id="draggable" class="ui-widget-content">
<p>Original</p>
</div>
<div id="draggable2" class="ui-widget-content">
<p>Semi-transparent clone</p>
</div>
<div id="draggable3" class="ui-widget-content">
<p>Custom helper (in combination with cursorAt)</p>
</div>
<h3 class="docs">Stacked:</h3>
<div id="set">
<div class="ui-widget-content">
<p>We are draggables..</p>
</div>
<div class="ui-widget-content">
<p>..whose z-indexes are controlled automatically..</p>
</div>
<div class="ui-widget-content">
<p>..with the stack option.</p>
</div>
</div>
<div class="demo-description">
<p>Provide feedback to users as they drag an object in the form of a helper. The <code>helper</code> option accepts the values 'original' (the draggable object moves with the cursor), 'clone' (a duplicate of the draggable moves with the cursor), or a function that returns a DOM element (that element is shown near the cursor during drag). Control the helper's transparency with the <code>opacity</code> option.</p>
<p>To clarify which draggable is in play, bring the draggable in motion to front. Use the <code>zIndex</code> option to set a higher z-index for the helper, if in play, or use the <code>stack</code> option to ensure that the last item dragged will appear on top of others in the same group on drag stop.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/visual-feedback.html | HTML | bsd | 2,635 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Draggable - Auto-scroll</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.mouse.js"></script>
<script src="../../ui/jquery.ui.draggable.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#draggable, #draggable2, #draggable3 { width: 100px; height: 100px; padding: 0.5em; float: left; margin: 0 10px 10px 0; }
</style>
<script>
$(function() {
$( "#draggable" ).draggable({ scroll: true });
$( "#draggable2" ).draggable({ scroll: true, scrollSensitivity: 100 });
$( "#draggable3" ).draggable({ scroll: true, scrollSpeed: 100 });
});
</script>
</head>
<body>
<div id="draggable" class="ui-widget-content">
<p>Scroll set to true, default settings</p>
</div>
<div id="draggable2" class="ui-widget-content">
<p>scrollSensitivity set to 100</p>
</div>
<div id="draggable3" class="ui-widget-content">
<p>scrollSpeed set to 100</p>
</div>
<div style='height: 5000px; width: 1px;'></div>
<div class="demo-description">
<p>Automatically scroll the document when the draggable is moved beyond the viewport. Set the <code>scroll</code> option to true to enable auto-scrolling, and fine-tune when scrolling is triggered and its speed with the <code>scrollSensitivity</code> and <code>scrollSpeed</code> options.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/draggable/scroll.html | HTML | bsd | 1,557 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Button - Toolbar</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.button.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
#toolbar {
padding: 10px 4px;
}
</style>
<script>
$(function() {
$( "#beginning" ).button({
text: false,
icons: {
primary: "ui-icon-seek-start"
}
});
$( "#rewind" ).button({
text: false,
icons: {
primary: "ui-icon-seek-prev"
}
});
$( "#play" ).button({
text: false,
icons: {
primary: "ui-icon-play"
}
})
.click(function() {
var options;
if ( $( this ).text() === "play" ) {
options = {
label: "pause",
icons: {
primary: "ui-icon-pause"
}
};
} else {
options = {
label: "play",
icons: {
primary: "ui-icon-play"
}
};
}
$( this ).button( "option", options );
});
$( "#stop" ).button({
text: false,
icons: {
primary: "ui-icon-stop"
}
})
.click(function() {
$( "#play" ).button( "option", {
label: "play",
icons: {
primary: "ui-icon-play"
}
});
});
$( "#forward" ).button({
text: false,
icons: {
primary: "ui-icon-seek-next"
}
});
$( "#end" ).button({
text: false,
icons: {
primary: "ui-icon-seek-end"
}
});
$( "#shuffle" ).button();
$( "#repeat" ).buttonset();
});
</script>
</head>
<body>
<span id="toolbar" class="ui-widget-header ui-corner-all">
<button id="beginning">go to beginning</button>
<button id="rewind">rewind</button>
<button id="play">play</button>
<button id="stop">stop</button>
<button id="forward">fast forward</button>
<button id="end">go to end</button>
<input type="checkbox" id="shuffle" /><label for="shuffle">Shuffle</label>
<span id="repeat">
<input type="radio" id="repeat0" name="repeat" checked="checked" /><label for="repeat0">No Repeat</label>
<input type="radio" id="repeat1" name="repeat" /><label for="repeat1">Once</label>
<input type="radio" id="repeatall" name="repeat" /><label for="repeatall">All</label>
</span>
</span>
<div class="demo-description">
<p>
A mediaplayer toolbar. Take a look at the underlying markup: A few button elements,
an input of type checkbox for the Shuffle button, and three inputs of type radio for the Repeat options.
</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/button/toolbar.html | HTML | bsd | 2,586 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Button Demos</title>
</head>
<body>
<ul>
<li><a href="default.html">Default functionality</a></li>
<li><a href="radio.html">Radios</a></li>
<li><a href="checkbox.html">Checkboxes</a></li>
<li><a href="icons.html">Icons</a></li>
<li><a href="toolbar.html">Toolbar</a></li>
<li><a href="splitbutton.html">Split Button</a></li>
</ul>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/button/index.html | HTML | bsd | 437 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Button - Icons</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.button.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "button:first" ).button({
icons: {
primary: "ui-icon-locked"
},
text: false
}).next().button({
icons: {
primary: "ui-icon-locked"
}
}).next().button({
icons: {
primary: "ui-icon-gear",
secondary: "ui-icon-triangle-1-s"
}
}).next().button({
icons: {
primary: "ui-icon-gear",
secondary: "ui-icon-triangle-1-s"
},
text: false
});
});
</script>
</head>
<body>
<button>Button with icon only</button>
<button>Button with icon on the left</button>
<button>Button with two icons</button>
<button>Button with two icons and no text</button>
<div class="demo-description">
<p>Some buttons with various combinations of text and icons, here specified via metadata.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/button/icons.html | HTML | bsd | 1,201 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Button - Radios</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.button.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#radio" ).buttonset();
});
</script>
</head>
<body>
<form>
<div id="radio">
<input type="radio" id="radio1" name="radio" /><label for="radio1">Choice 1</label>
<input type="radio" id="radio2" name="radio" checked="checked" /><label for="radio2">Choice 2</label>
<input type="radio" id="radio3" name="radio" /><label for="radio3">Choice 3</label>
</div>
</form>
<div class="demo-description">
<p>A set of three radio buttons transformed into a button set.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/button/radio.html | HTML | bsd | 952 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Button - Default functionality</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.button.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "input[type=submit], a, button" )
.button()
.click(function( event ) {
event.preventDefault();
});
});
</script>
</head>
<body>
<button>A button element</button>
<input type="submit" value="A submit button">
<a href="#">An anchor</a>
<div class="demo-description">
<p>Examples of the markup that can be used for buttons: A button element, an input of type submit and an anchor.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/button/default.html | HTML | bsd | 896 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Button - Checkboxes</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.button.js"></script>
<link rel="stylesheet" href="../demos.css">
<script>
$(function() {
$( "#check" ).button();
$( "#format" ).buttonset();
});
</script>
<style>
#format { margin-top: 2em; }
</style>
</head>
<body>
<input type="checkbox" id="check" /><label for="check">Toggle</label>
<div id="format">
<input type="checkbox" id="check1" /><label for="check1">B</label>
<input type="checkbox" id="check2" /><label for="check2">I</label>
<input type="checkbox" id="check3" /><label for="check3">U</label>
</div>
<div class="demo-description">
<p>A checkbox is styled as a toggle button with the button widget. The label element associated with the checkbox is used for the button text.</p>
<p>This demo also demonstrates three checkboxes styled as a button set by calling <code>.buttonset()</code> on a common container.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/button/checkbox.html | HTML | bsd | 1,230 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Button - Split button</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.button.js"></script>
<script src="../../ui/jquery.ui.position.js"></script>
<script src="../../ui/jquery.ui.menu.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.ui-menu { position: absolute; width: 100px; }
</style>
<script>
$(function() {
$( "#rerun" )
.button()
.click(function() {
alert( "Running the last action" );
})
.next()
.button({
text: false,
icons: {
primary: "ui-icon-triangle-1-s"
}
})
.click(function() {
var menu = $( this ).parent().next().show().position({
my: "left top",
at: "left bottom",
of: this
});
$( document ).one( "click", function() {
menu.hide();
});
return false;
})
.parent()
.buttonset()
.next()
.hide()
.menu();
});
</script>
</head>
<body>
<div>
<div>
<button id="rerun">Run last action</button>
<button id="select">Select an action</button>
</div>
<ul>
<li><a href="#">Open...</a></li>
<li><a href="#">Save</a></li>
<li><a href="#">Delete</a></li>
</ul>
</div>
<div class="demo-description">
<p>An example of a split button built with two buttons: A plain button with just text, one with only a primary icon
and no text. Both are grouped together in a set.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/button/splitbutton.html | HTML | bsd | 1,662 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Tooltip - Video Player demo</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.position.js"></script>
<script src="../../ui/jquery.ui.tooltip.js"></script>
<script src="../../ui/jquery.ui.button.js"></script>
<script src="../../ui/jquery.ui.menu.js"></script>
<script src="../../ui/jquery.ui.effect.js"></script>
<script src="../../ui/jquery.ui.effect-blind.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
.player {
width: 500px;
height: 300px;
border: 2px groove gray;
background: rgb(200, 200, 200);
text-align: center;
line-height: 300px;
}
.ui-tooltip {
border: 1px solid white;
background: rgba(20, 20, 20, 1);
color: white;
}
.set {
display: inline-block;
}
.notification {
position: absolute;
display: inline-block;
font-size: 2em;
padding: .5em;
box-shadow: 2px 2px 5px -2px rgba(0,0,0,0.5);
}
</style>
<script>
$(function() {
function notify( input ) {
var msg = "Selected " + $.trim( input.data( "tooltip-title" ) || input.text() );
$( "<div>" )
.appendTo( document.body )
.text( msg )
.addClass( "notification ui-state-default ui-corner-bottom" )
.position({
my: "center top",
at: "center top",
of: window
})
.show({
effect: "blind"
})
.delay( 1000 )
.hide({
effect: "blind",
duration: "slow"
}, function() {
$( this ).remove();
});
}
$( "button" ).each(function() {
var button = $( this ).button({
icons: {
primary: $( this ).data( "icon" )
},
text: !!$( this ).attr( "title" )
});
button.click(function() {
notify( button );
});
});
$( ".set" ).buttonset({
items: "button"
});
$( document ).tooltip({
position: {
my: "center top",
at: "center bottom+5",
},
show: {
duration: "fast"
},
hide: {
effect: "hide"
}
});
});
</script>
</head>
<body>
<div class="player">Here Be Video (HTML5?)</div>
<div class="tools">
<span class="set">
<button data-icon="ui-icon-circle-arrow-n" title="I like this">Like</button>
<button data-icon="ui-icon-circle-arrow-s">I dislike this</button>
</span>
<div class="set">
<button data-icon="ui-icon-circle-plus" title="Add to Watch Later">Add to</button>
<button class="menu" data-icon="ui-icon-triangle-1-s">Add to favorites or playlist</button>
</div>
<button title="Share this video">Share</button>
<button data-icon="ui-icon-alert">Flag as inappropiate</button>
</div>
<div class="demo-description">
<p>A fake video player with like/share/stats button, each with a custom-styled tooltip.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/tooltip/video-player.html | HTML | bsd | 2,911 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Tooltip - Forms</title>
<link rel="stylesheet" href="../../themes/base/jquery.ui.all.css">
<script src="../../jquery-1.8.2.js"></script>
<script src="../../ui/jquery.ui.core.js"></script>
<script src="../../ui/jquery.ui.widget.js"></script>
<script src="../../ui/jquery.ui.position.js"></script>
<script src="../../ui/jquery.ui.tooltip.js"></script>
<script src="../../ui/jquery.ui.button.js"></script>
<link rel="stylesheet" href="../demos.css">
<style>
label {
display: inline-block; width: 5em;
}
fieldset div {
margin-bottom: 2em;
}
fieldset .help {
display: inline-block;
}
.ui-tooltip {
width: 210px;
}
</style>
<script>
$(function() {
var tooltips = $( "[title]" ).tooltip();
$( "<button>" )
.text( "Show help" )
.button()
.click(function() {
tooltips.tooltip( "open" );
})
.insertAfter( "form" );
});
</script>
</head>
<body>
<form>
<fieldset>
<div>
<label for="firstname">Firstname</label>
<input id="firstname" name="firstname" title="Please provide your firstname.">
</div>
<div>
<label for="lastname">Lastname</label>
<input id="lastname" name="lastname" title="Please provide also your lastname.">
</div>
<div>
<label for="address">Address</label>
<input id="address" name="address" title="Your home or work address.">
</div>
</fieldset>
</form>
<div class="demo-description">
<p>Use the button below to display the help texts, or just focus or mouseover the indivdual inputs.</p>
<p>A fixed width is defined in CSS to make the tooltips look consistent when displayed all at once.</p>
</div>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/tooltip/forms.html | HTML | bsd | 1,690 |
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Tooltip Demos</title>
</head>
<body>
<ul>
<li><a href="default.html">Default functionality</a></li>
<li><a href="custom-style.html">Custom style with arrow</a></li>
<li><a href="forms.html">Forms with tooltips</a></li>
<li><a href="tracking.html">Track the mouse</a></li>
<li><a href="custom-animation.html">Custom animation</a></li>
<li><a href="custom-content.html">Custom content</a></li>
<li><a href="video-player.html">Video Player</a></li>
</ul>
</body>
</html>
| 10bit1-group02-pmproject | trunk/Temp_Source/WUC/jquery-ui-1.9.1.custom/development-bundle/demos/tooltip/index.html | HTML | bsd | 559 |