public FluentElement <T> Style(params Styles[] styles)
 {
     foreach (var style in styles)
     {
         FluentUITK.DefineStyle(x, style);
     }
     return(x);
 }
        public FluentElement <T> Insert(int index, VisualElement element)
        {
            FluentUITK.AddCoreStyles(element);

            x.Insert(index, element);
            onAddChild?.Invoke(element);

            return(x);
        }
        public FluentElement <PropertyField> NewField <TSource>(Expression <Func <TSource, object> > member, string label = null)
        {
            #if UNITY_EDITOR
            var bindingPath = FluentUITK.GetMemberPath(member);

            return(new PropertyField {
                bindingPath = bindingPath, label = label
            });
            #else
            return(null);
            #endif
        }
 internal FluentElement <T> AddCoreStyles()
 {
     FluentUITK.AddCoreStyles(x); return(x);
 }
Пример #5
0
 public static Texture2D GetEditorIcon(string iconName) => FluentUITK.GetEditorIcon(iconName);
Пример #6
0
 public static Texture2D GetTypeIcon(Type type) => FluentUITK.GetTypeIcon(type);
Пример #7
0
 public static Texture2D GetTypeIcon <TType>() => FluentUITK.GetTypeIcon <TType>();
Пример #8
0
 public static Texture2D GetObjectIcon(Object obj, Type type = null)
 {
     return(FluentUITK.GetObjectIcon(obj, type));
 }
Пример #9
0
 public static TType FindAsset <TType>(string name = null, string guid = null) where TType : Object
 {
     return(FluentUITK.FindAsset <TType>(name, guid));
 }
Пример #10
0
 public static IEnumerable <Object> FindAssets(Type type, string name = null)
 {
     return(FluentUITK.FindAssets <Object>(name));
 }
Пример #11
0
 public static IEnumerable <TType> FindAssets <TType>(string name = null) where TType : Object
 {
     return(FluentUITK.FindAssets <TType>(name));
 }
Пример #12
0
 public static StyleSheet FindStyleSheet(string name = null, string guid = null)
 {
     return(FluentUITK.FindStyleSheet(name, guid));
 }
 /// <summary> Returns all callbacks registered to this element. </summary>
 public IEnumerable <FluentUITK.EventFunctor> GetCallbacks()
 {
     return(FluentUITK.GetCallbacks(x));
 }
 public FluentElement <T> Unregister(CallHandle handle)
 {
     FluentUITK.UnregisterCallback(x, handle.eventTypeId, handle.callback, handle.trickle);
     return(x);
 }
 public FluentElement <T> Style(Styles styles)
 {
     FluentUITK.DefineStyle(x, styles);
     return(x);
 }
        /// <summary> Retrieves full path of a source member and sets it as a binding path. </summary>
        public FluentElement <T> Bind <TSource>(Expression <Func <TSource, object> > member)
        {
            var fullPath = FluentUITK.GetMemberPath(member);

            Bind(fullPath); return(x);
        }