Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Build in column filter - filter button hint

    Is there a way I can set the hint for the filter button for the built in column filter?

    TIA,

    #2
    Which filter button do you mean? The one that looks like a funnel in the upper-right hand corner of a grid showing a FilterEditor?

    Comment


      #3
      Yes, I search and there is not setToolTip on the funnel.

      Comment


        #4
        You're correct, there's no way to do so, we consider it self-explanatory. If you desperately want to add a prompt, you could locate the Button in the ListGrid's children (or children of children) after draw and setPrompt() on it.

        Comment


          #5
          I thought so too, but our user are insistent that this is a bug. I guess, I can try your solution. Maybe you can add a simple method in your next build?

          Thanks,

          Comment


            #6
            Ok - setFilterButtonProperties() has been added - you should be able to use this to customize the button -- for example setting a prompt on it.

            Example usage would look something like this:
            Code:
            Button filterConfig = new Button();
            filterConfig.setPrompt("Click this button to filter the data");
            
            myListGrid.setFilterButtonProperties(filterConfig);

            Comment


              #7
              I use:

              Code:
              Button btn = new Button("Aha!!!");
                      btn.setWidth(150);
                      btn.setBackgroundColor("red");
                      grid.setFilterButtonProperties(btn);
              And the only property applied was the background color.
              Any clue about what's wrong?

              Comment


                #8
                Anyone can help on this?

                Comment


                  #9
                  The width of the button is always set to fit the available space in the grid (it matches the width of the scrollbar and the sort button.
                  This can't be customized within the current framework since it would break the layout of the filter-editor (careful sizing of fields to match grid fields, etc).

                  If you specified "icon:null" the buttons icon would be suppressed and you'd see your title, but this isn't going to look good in most cases.

                  In short it sounds like you're looking for a totally custom filter button. This isn't currently supported but you could easily add another button to your application that the user clicks to filter the grid based on the criteria currently entered in the filterEditor.

                  Comment


                    #10
                    But the grid button has to be present, am I right?

                    Comment

                    Working...
                    X