custom-component

How do I create a custom text field in Tapestry5 that renders some Javascript onto the page?

我怕爱的太早我们不能终老 提交于 2019-12-08 06:35:58
问题 I have been trying to create a custom textfield in tapestry which will render some javascript when it gains focus. But I have been having trouble trying to find an example of this. Here is some of the code i have started off with: package asc.components; import org.apache.tapestry5.ComponentResources; import org.apache.tapestry5.Field; import org.apache.tapestry5.annotations.Parameter; import org.apache.tapestry5.ioc.annotations.Inject; import org.apache.tapestry5.services

how to access super component class variable into sub component Class?

扶醉桌前 提交于 2019-12-08 00:27:09
问题 How i access super component class variable into sub component in Angular2? super Component Article.ts @Component({ selector: 'article' }) @View({ templateUrl: './components/article/article.html?v=<%= VERSION %>', styleUrls : ['./components/article/article.css'], directives: [CORE_DIRECTIVES, AmCard, NgFor] }) export class Article{ articleArr : Array; constructor() { this.articleArr = new Array(); } articleSubmit(articleSubject, articleName, articleUrl) { this.articleArr.push({title:

Converting Delphi 7 property editor to Delphi XE2

拥有回忆 提交于 2019-12-07 19:10:27
问题 First of all, I have never written a property editor from scratch, but had some help with one in another question. Refer to the accepted answer there. This was in Delphi 7, and now I have started using XE2 and I have to make sure my property editor is compatible with both 7 and XE2. It's essentially a collection editor, with the difference that each collection item has its own named component in the parent form. Is there anything new about the property editors in XE2 since 7, since it is a

Extend Richfaces components - for example customize Datatable component for specific implementation

自古美人都是妖i 提交于 2019-12-07 12:48:10
问题 How to extend the functionality of Richfaces components for example Data table with custom header and sorting techniques. i have seen extended data table but did not get much information from it. Please point me to an example if at it is available. Thanks Soma 回答1: Well, you can extend a JSF component with the regular java extension ( extends ). You will have to extend a number of classes, depending on the exact component: UIComponentName / HtmlComponentName HtmlComponentNameRenderer

Delphi visual component - moving away from TFrame base? [closed]

不问归期 提交于 2019-12-07 12:25:28
问题 As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 7 years ago . I have a visual component that I built from a TFrame (but then registered to the palette, etc); it works great and I loved being able

Custom Attribute Error - Android Studio 1.2

最后都变了- 提交于 2019-12-07 02:39:38
问题 In my Android project I have a couple of custom components that use custom attributes. The attrs.xml file looks like this: <?xml version="1.0" encoding="utf-8"?> <resources > <declare-styleable name = "TextBox"> <attr name = "font" format = "string"/> </declare-styleable> <declare-styleable name = "ButtonBox"> <attr name = "font" format = "string"/> </declare-styleable> </resources> I am pulling in the attributes just fine in the custom component, but when I go to run the code I see the

Android : how to create custom component

纵饮孤独 提交于 2019-12-06 14:52:11
Any one please guide me, How to create a custom component in xml and java file pass attributes from xml (this i somewhat completed) how to pass attributes dynamically from new customClass() -- constructor method. -- i dont know how to implement this point for Eg : I created a custom component with two textview as a single component. In xml i created two component by xml attributes. Now i want to create two new component by java code by calling the constructor of my customClass.java I dont know how to create a new component dynamically from java code and how to display that in a view(Say a

How to add to the layout compound component programmatically Android?

南楼画角 提交于 2019-12-06 14:22:10
I created a compound component Box which I want to add to the layout. Box xml: <?xml version="1.0" encoding="utf-8"?> <merge xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/linearLayoutForBlock" android:layout_width="wrap_content" android:layout_height="wrap_content" android:orientation="vertical"> <LinearLayout android:id="@+id/linearLayout1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:orientation="vertical" android:background="@drawable/screen_background" android:layout_marginLeft="5dp" android:layout_marginTop="5dp">

What is File’s owner in XIB in this case?

半城伤御伤魂 提交于 2019-12-06 11:39:52
问题 I've searched for similar questions for quite a while, most of which mentioned UIViewController's xib stuff. I tried to add a xib file for my custom viewController model,and found that its Xib’s File’s Owner should be my custom viewController model's class--that is reasonable. But why the situation differs when i create a xib for my UIView model -- an example as follows: I create my UIView model which named "KWView"(KWView.h and KWView.m) then i create xib for this model, initializing it by

Drawing an overlay in custom flex component

限于喜欢 提交于 2019-12-06 11:18:35
问题 How would one create a custom MXML component in flex which is based on an existing component but draws an overlay over this existing component in certain situations. Ideally, the new component should be based on (derive from) the exiting component so that occurrences of the existing component could just be swapped out with the new one. I tried to override updateDisplayList() in the new component and to paint the overlay using this.graphics. This resulted in the overlay being drawn underneath