B4i Library iComboBox - Easy way to put combo in your B4i apps

Discussion in 'iOS Libraries' started by Alberto Iglesias, Mar 11, 2015.

  1. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    [​IMG]

    Installation instructions:

    - Copy the *.a and *.h files into the folder "Libs" in your MAC or in your MAC HOSTED by AnywhereSoftware, normally in "B4i-MacServer\Libs" folder

    -Copy the iComboBox.xml to your custom libraries folder in B4i
    - Select in your REFERENCED LIBRARIES
    [​IMG]

    Version history:
    V1.0.0 (First public release):
    - Initial version

    V1.0.2
    - New method to move combo after initialized (.moveCombo(x,y,width,height)

    V1.0.3
    - New methods:
    * SetText
    * SetPlaceHolder

    V1.0.4

    Obs: From this version is not necessary replace the libraries to convert to the FULL VERSION, now by simply put your license in the LicenseKey and LicenseEmail in appropriate properties.

    - New methods:

    * ColorBackground
    * SetTextWithColor
    * SetPlaceHolderWithColor

    * LicenseEmail
    * LicenseKey
    * LicenseShow

    CHECK NEW EXAMPLE ATTACHED IN HERE: ExampleWithLicenseKey.zip



    iComboBox
    Author:
    Alberto Iglesias (alberto@visualnet.inf.br)
    Version: 1.0.2
    • iComboBox
      Events:
      • onInitialized (EventName As String)
      • onSelected (itemName as String )
      Methods:
      • AddSection (SectionName As String, MenuItens As Array)
        Add a section to combo with itens
      • ColorHeadSection (Rt As Int, Gt As Int, Bt As Int, Rb As Int, Gb As Int, Bb As Int)
        Set the colors of Head Section
      • Initialize (EventName As String, defaultPlaceHolder As String, x As Int, y As Int, width As Int, height As Int, expandHeight As Int, allowFiltering As BOOL, iconArrow As NSString*)
      • moveCombo(x AsInt, y AsInt, width AsInt, height AsInt)
        Initializes the object.
      • Show (Parent As B4IPage*)
        Show the Combo
      Properties:
      • Author As String [read only]
        Author of this Library
      • DebugMode As BOOL
        Enable/Disable Debug mode from Library
      • LastItemChoosed As String [read only]
        Last Title of Item Choosed
      • LastSectionChoosed As String [read only]
        Last Section Name Choosed
      • NameIdentifier As String [read only]
        Name of Combo Identifier
      • SectionTitleEnable As BOOL
        Enable/Disable Title of Section
      • UUID As String [read only]
        UUID Identifier
      • Version As String [read only]
        Library Version
      • borderWidth As Int
        Width of Combo border

    [​IMG]




    [​IMG]
     

    Attached Files:

    Last edited: Feb 5, 2016
    Derek Johnson, Ohanian and inakigarm like this.
  2. johan vetsuypens

    johan vetsuypens Member Licensed User

    Hello Alberto,

    What is the licence policy on this library ?

    thanks,
    Johan
     
  3. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    what license policy?
     
  4. tucano2000

    tucano2000 Active Member Licensed User

    I am testing on local Builder and B4i IDE return this error when compiling... Is not possible to find file c:\program files... \zone.identifier

    Captura de Tela 2015-03-30 às 09.33.54.png
     
  5. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    Brasileiro?

    I don´t know what is this file Zone.Identifier?

    Maybe Erel knows.....
     
  6. tucano2000

    tucano2000 Active Member Licensed User

    Sim. Sou Brasileiro Alberto. Você é também ? será que não é um problema com o xml ? Porque quando uso Test Compiling não da erro. Os outros projetos estão compilando normalmente.
     
  7. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    Beleza, eu tambem... Um usuario teve problema com a versao do Java que estava utilizando, depois que atualizou foi legal.

    O projeto de exemplo que está junto com o iComboBox te funcionou?
     
  8. tucano2000

    tucano2000 Active Member Licensed User

    Sim esse problema aconteceu nos 2 exemplos que vc postou. Mas já consegui resolver. Eu criei outro projeto em branco no B4i e copiei o código exemplo para ele e depois disso compilou com sucesso.

    Eu descobri que no arquivo zip que vc postou, tem 3 arquivos : iComboBox.b4i.meta, iComboBox.meta.Zone.Identifier e iComboBox.Zone.Identifier e no outro projeto que eu criei tem somente o meuprojeto.b4i.meta.

    Realmente é alguma coisa do B4i IDE.

    Uma sugestão para seu combobox. Caso o usuário não queira escolher nenhuma opção da combo, se ele tocar em outra parte da tela a combo voltar ao estado anterior antes da escolha visto que o iOS não tem um botão voltar como no Android. Isso tira a sensação de obrigar o usuário de escolher algo. Ou eu que terei que fazer isso no meu código se usar sua biblioteca ? O que acha ?
     
    Last edited: Mar 30, 2015
  9. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    Legal, vou implementar essa opção, pode ser bem util para o usuário.
     
  10. tucano2000

    tucano2000 Active Member Licensed User

    Ou senão tocar no próprio botão que abre a combo para ela fechar e deixar a tela livre sem que uma escolha for feita. Mas valeu só uma sugestão, desculpe a intromissão. Boa sorte e sucesso nos seus projetos.
     
  11. miquelr

    miquelr Member Licensed User

    Hi,
    How I can access to my hosted folder "B4i-MacServer\Libs"?
     
  12. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    if you dont have a Mac, you need ask to Erel... :-(
     
  13. Erel

    Erel Administrator Staff Member Licensed User

    I've uploaded the library to the hosted builders.
     
  14. mcGeorge

    mcGeorge Member Licensed User

    Hi Alberto,

    i love your Combobox. Now I wanted to use your Combobox together with the AnotherDatePicker-Class from Erel. But if i show the DatePicker, your Combobox overlapped. See the Picture please.

    How do I get your combo box in the background?

    Thanks for your answer.
    George
     

    Attached Files:

  15. Derek Johnson

    Derek Johnson Active Member Licensed User

    A great implentation of a combobox, just one thing I noticed though.

    When you use:

    objCombo.SectionTitleEnable = True

    it is possible to type a name into the combobox.

    However when you hit ENTER, this does not raise any event. So it is not possible to detect that this has happened.

    It works just fine as a drop-down list selector though.

    (I like your nag-ware feature too - will have to make a donation soon!)

    Derek
     
  16. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    :) ok thanks! I will see the event for enter and tell you
     
    Derek Johnson likes this.
  17. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    Hello mcGeorge, I don´t see your message, I will check this too... don´t worry
     
  18. Derek Johnson

    Derek Johnson Active Member Licensed User

    Alberto,

    Thanks for the fast response!

    If you are making some changes, I would like to suggest that you add another property:

    'CanInputText'

    This should control whether this is a true combo-box or just a drop-down list. At the moment it is controlled by the property 'SectionTitleEnable', this does not seem quite correct.

    (Just a suggestion) :)

    Derek
     
  19. Alberto Iglesias

    Alberto Iglesias Well-Known Member Licensed User

    Hello Derek,

    Can you try this beta version? Now with Return event, I mean, when you type and pulse ENTER, works like choose a list item.


    Alberto Iglesias
     

    Attached Files:

  20. Derek Johnson

    Derek Johnson Active Member Licensed User

    I think that I may have a problem testing this - I use the hosted builder and this is an updated library, so it would require Erel to host the modified library, or perhaps some other helpful user can test this.

    Derek
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice