own definition button in two different states of the picture//unchecked state is displayed after the first picture is selected is a picture behind [Button3 setimage:[uiimage imagenamed:@ "[emailprotected]" ] Forstate:uicontrolstatenormal]; [Button3 setimage:[uiimage imagenamed:@ "[emailprotected]"] forstate:uicontrolstateselected]; [Button3 ADDtarget:self Action: @selector (click:) forcontrolevents:uicontroleventtouchupinside]; [Self.view Addsubview:button3]; }//assume that there a
PHP development framework YiiFramework tutorial (16) UI component StarRating example
CStarRating is mainly used for scoring. a group of stars (five stars) are displayed for scoring.
The basic usage is as follows:
BeginWidget ('cactiveform');?>
Widget ('cstarrating', array ('Model' => $ model,'Attribute' => 'rating ','Name' => 'rating ','Value' => 3,);?>
EndWidget ();?>
In th
PHP development framework YiiFramework tutorial (12) UI component ClipWidget example
The CClipWidget provides a function similar to the recording "macro". the content defined between the init and run of the CClipWidget can be stored in the Clip variable of the Controller, and then played back to any other location.
CClipWidget encapsulates the beginClip and endClip of CBaseController. The basic usage of beg
=nslinebreakbytruncatingtail;Nslinebreakbycharwrapping: Wrapping in characters, truncating content in charactersNslinebreakbywordwrapping: Wrapping in words, truncating content in wordsNslinebreakbyclipping: Wrapping in words, truncating content in charactersNslinebreakbytruncatinghead: To ... Omit the previous content, if there are multiple lines, ... will be placed on the last lineNslinebreakbytruncatingmiddle: Omit intermediate content ..., if there is more than one line, omit the middle of t
set a custom button a different picture in two states//unchecked state is the first picture selected after a picture [Button3 setimage:[uiimage imagenamed:@ "[emailprotected]"] Forstate:uicontrolstatenormal]; [Button3 setimage:[uiimage imagenamed:@ "[emailprotected]"] forstate:uicontrolstateselected]; [Button3 AddTArget:self Action: @selector (click:) forcontrolevents:uicontroleventtouchupinside]; [Self.view Addsubview:button3]; }//If you have more than one button to trigger the sa
I recently purchased the color software for the Android platform. Today I have some experience in implementing UI events, that is, I should try to use the interface listening callback mechanism. In fact, many Android components have interfaces in this regard, you can also refer to this mode when customizing components by yourself. As for interface registration, you can declare the implementation in XML, which can effectively reduceCodeQuantity. We als
ProgressBar (progress bar) components, this is quite fun, we do something in our own time often can be used, such as uploading download files, import and export documents, loading pages and so on.There are a lot of scenarios and it's easy to use them.Example:Execution effect:Click to download source codeJQuery Easy UI ProgressBar (progress bar) component
state of the contact slipWhen you click on the contact sheet view in the off state, it expands and displays the address of the contact person.
By default, the topmost contact is activated and selected
The font of the contact name is: Roboto, General, 16SP
The font for address text is: Roboto, General, 14SP
When the user chooses, the paper view is closed as shown: Copyright NOTICE: When we seriously to do one thing, we can find the endless fun, colorful technology like the
PHP development framework YiiFramework tutorial (17) UI component TabView example
CTabView is used to display Tab pages. The basic way to use TabView is to configure the tabs attribute. the following attributes can be configured for each Tab.
Title: tag question.
Content: the content displayed by the tag.
View: The label displays the View Name. if both the Content is specified, the Content is displayed.
Url
PHP development framework YiiFramework tutorial (13) UI component ContentDecorator example
Similar to Layout in Yii Framework in Java Swing, nesting is also allowed, which is implemented through CContentDecorator. However, you do not need to directly use CContentDecorator in the code, but use it in the definition of layout.
$ This-> beginContent ('path/to/view ');//... Content to be decorated$ This-> endCon
Function DataGridToExcel (ByVal dgExport As C1.Web. Wijmo. Controls. C1GridView. C1GridView) As String
'Create a stringwriter
Dim stringWrite As New System. IO. StringWriter ()
'Create an htmltextwriter that uses the stringwriter
Dim htmlWrite As New System. Web. UI. HtmlTextWriter (stringWrite)
Dim dg As C1.Web. Wijmo. Controls. C1GridView. C1GridView
'Just set the input datagrid = to the new dg grid
Dg = dgExport
, ') '), Array (' text ' = = ') ID ' = ' 8 ', ' haschildren ' = ' = ', ' Children ' =>array (Array (' text ' = ' + ' id ' = ' + ') ', ' haschildren ' = FA LSE,), array (' text ' = ' + ' id ' = ' + ', ' HasChildren ' + false)))));
This adds a link to the text for each node, and also shows the click events using the jquery response node, which is done through the client javascripts.
Modify the View definition
$cs =yii::app ()->clientscript; $cs->registerscript (' Menutreeclick ', "jQuery (' #menu-
Cclipwidget provides the ability to record "macros", and the content defined between Init and run of Cclipwidget can be stored in the controller's clip variable and replayed back to any other location.
Cclipwidget encapsulates the basic usage of beginclip and endclip for Cbasecontroller Beginclip and Endclip,cbasecontroller as follows:
First define Clip
$this->beginclip (' clipid ');//... display the clip contents$this->endclip ();
And then we need to use this clip.
echo $this->clips[' clipid '
example, CActiveForm is used. CActiveForm also provides seamless and consistent verification between the client and the server.
>beginWidget('CActiveForm', array('id'=>'user-form','enableAjaxValidation'=>true,'enableClientValidation'=>true,'focus'=>array($model,'firstName'),)); ?>
This example is relatively simple. without these complex verifications, only FirstName and LastName are required. this is defined by the required of rules in DataModel.
BeginWidget ('cactiveform');?> ErrorSummary ($
the following line when in production mode// defined('YII_DEBUG') or define('YII_DEBUG',true);require_once($yii);Yii::createWebApplication($config)->run();endWidget(); ?>PHP code with Line NumberbeginWidget('CTextHighlighter',array('language'=>'PHP','showLineNumbers'=>'true')); ?>/*** SiteController is the default controller to handle user requests.*/class SiteController extends CController{/*** Index action is the default action in a controller.*/public function actionIndex(){$model=new DataMo
Introductionsince the introduction of different components of the jquery UI has similar characteristics and syntax, only two components are described hereis introduced, so that you can say how other components are introduced.Button buttons
Set the button button to UI
$ (' #button '). button ();
Dialog dialog box
Set Div To Dialog dialog box
$ (' #dialog '). Click (function () {
other apps that use the sliding Menu.
Cards: A very beautiful introduction to the UI component that will make your app look like Google home. You can add one or several cards to the screen.
3. Function libraryThe Android app is not just a UI, it also includes a lot of color and picture resources. Optimus Prime (translated: "The leader of the righteous s
As a beginner unity3d one months of small rookie, want to build a UI library is also quite crazy, but the eldest brother not to use Ngui, Then at that time Unity4.6 official version has not yet released (or I do not know that Unity4.6 has its own UI), and then the fearless write down, at present, although the function is very simple, the implementation of the con
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.