https://linen.dev logo
Join Discord
Powered by
# haxe-ui
  • b

    bright-gpu-74537

    08/12/2019, 11:47 AM
    i can get your example to populate, your item renderers are indeed wrong, but thats easy to fix
  • b

    bright-gpu-74537

    08/12/2019, 11:47 AM
    id like to remove the order thing first
  • l

    loud-salesclerk-7438

    08/12/2019, 11:50 AM
    I just tried using default ItemRenderer and it shows data, so it's definitely an ItemRenderer problem.... though it doesn't seem to matter when header gets added
  • b

    bright-gpu-74537

    08/12/2019, 11:53 AM
    yeah, in your project, but in another test project it did...
  • l

    loud-salesclerk-7438

    08/12/2019, 11:59 AM
    Another thing I noticed: Is there a replacement for
    selectedRow
    property that was available in previous versions?
  • m

    magnificent-caravan-75149

    08/12/2019, 4:52 PM
    @bright-gpu-74537 I'm using Kha as a backend (targeting Windows native but debuging in HTML). I know that I ran into an issue with trying to get Opacity changing with kha. I needed to use createRenderTarget for the image. I tried wrapping the image in a box as you suggested for the background image issue I was having. I tried style="opacity:0.5;" on both the box and image. I also tried style="background-opacity:0.5;" on both. In neither case was I able to get the opacity to change.
  • m

    magnificent-caravan-75149

    08/12/2019, 4:55 PM
    @bright-gpu-74537 However, the opacity does work on the background color as I would expect. So it appears that in order to get the opacity working for an image in kha, a renderTarget would need to be used. I'll play with it a bit more in kodegarden with just kha.
  • m

    magnificent-caravan-75149

    08/12/2019, 6:28 PM
    here's the kodegarden http://kodegarden.org/#95456b14bf92e5671604d957dc183c7d449b2464
  • l

    loud-salesclerk-7438

    08/12/2019, 9:45 PM
    @bright-gpu-74537 I've updated my demo, it now renders text and images correctly using a standard ItemRenderer (one per column)
  • b

    bright-gpu-74537

    08/13/2019, 7:42 AM
    @loud-salesclerk-7438 - just about to push some tableview fixes... few things:
  • b

    bright-gpu-74537

    08/13/2019, 7:44 AM
    * You dont need to add that last item anymore (or call invalidateComponentLayout after adding the ds) - oversight on my part * You dont really need to set the widths of item renderers (or the sub labels in your example)... you can ofc, but you can also just let haxeui do all tthat
  • b

    bright-gpu-74537

    08/13/2019, 7:44 AM
    you also had this:
  • b

    bright-gpu-74537

    08/13/2019, 7:44 AM
    Copy code
    // var renderer:ItemRenderer = new ItemRenderer();
            // tableView.addComponent(renderer);
    
            addImageColumn(header, tableView, "icon", 50);
            addImageColumn(header, tableView, "pdf", 50);
            for (index in 1...5) {
                addTextColumn(header, tableView, 'field_$index', 'Field $index', 100);
            }
  • b

    bright-gpu-74537

    08/13/2019, 7:45 AM
    that top item renderer isnt needed as its basically creating a empty renderer for no reason... just add item renderers (via addComponent) for each column as you are doing later
  • m

    magnificent-caravan-75149

    08/13/2019, 1:45 PM
    @bright-gpu-74537 I got the opacity to work but may not be able to use the animations.
  • m

    magnificent-caravan-75149

    08/13/2019, 1:48 PM
    @bright-gpu-74537 I made a separate xml with a "boxed" image, then built the components. In the render loop, I used the renderTo and the renderTarget. I could then change the opacity as I had been doing for the straight kha version of my init scene.
  • l

    loud-salesclerk-7438

    08/13/2019, 3:17 PM
    @bright-gpu-74537 can confirm last item no longer needed. My top item renderer was a leftover when I played with standard ItemRenderer... I was trying to use just one ItemRenderer, but TableView needs one per column.
  • m

    magnificent-caravan-75149

    08/13/2019, 6:41 PM
    I having a bit of a layout problem. I need to "reserve" the top half of the screen for rendering an image separately from HaxeUI. I'd like to use % (to take into account resizing) but the layout doesn't render correctly. What can I use to do this?
  • b

    bright-gpu-74537

    08/14/2019, 8:09 AM
    @loud-salesclerk-7438 - ive added full tableview selection fyi @magnificent-caravan-75149 - do you have an example?
  • l

    loud-salesclerk-7438

    08/14/2019, 8:50 AM
    nice, thanks!
  • b

    bright-gpu-74537

    08/14/2019, 9:45 AM
    @magnificent-caravan-75149 - so, making some opacity updates to haxeui-kha... so, with kha, how can i draw an Image with an opacity of, say, .5?
  • b

    bright-gpu-74537

    08/14/2019, 10:05 AM
    so fade works better now and also works with css animations
  • b

    bright-gpu-74537

    08/14/2019, 10:05 AM
    (kha)
  • b

    bright-gpu-74537

    08/14/2019, 10:05 AM
    Copy code
    xml
        <style>
            @keyframes fade {
                0% {
                    opacity: 0;
                }
                100% {
                    opacity: 1;
                }
            }
            
            #ex1.fadeIn, #ex2.fadeIn, #ex3.fadeIn {
                animation: fade 0.5s ease 0s 1;
            }
            
            #ex1.fadeOut, #ex2.fadeOut, #ex3.fadeOut {
                animation: fade 0.5s ease 0s 1 reverse backwards;
            }
            
        </style>
        
        <hbox>
            <image id="ex1" resource="haxeui-core/styles/default/haxeui.png" style="opacity: 0;" />
            <vbox>
                <button id="ex2" text="Some Button" style="opacity: 0;font-size:24px;" />
                <progress id="ex3" pos="50" style="opacity: 0;" />
            </vbox>    
        </hbox>
        <hbox>
            <button text="fadeIn" onclick="ex1.swapClass('fadeIn', 'fadeOut');ex2.swapClass('fadeIn', 'fadeOut');ex3.swapClass('fadeIn', 'fadeOut')" />
            <button text="fadeOut" onclick="ex1.swapClass('fadeOut', 'fadeIn');ex2.swapClass('fadeOut', 'fadeIn');ex3.swapClass('fadeOut', 'fadeIn')" />
        </hbox>
  • l

    loud-salesclerk-7438

    08/14/2019, 10:07 AM
    TableView selection seems broken... when you select an item further down the list (e.g. you scroll down first), it will show all of them in selected state and scroll up
  • b

    bright-gpu-74537

    08/14/2019, 10:07 AM
    oh? :/
  • b

    bright-gpu-74537

    08/14/2019, 10:09 AM
    im probably not following, but i cant repro
  • b

    bright-gpu-74537

    08/14/2019, 10:13 AM
    oh... i can repro... its for virtual tables
  • l

    loud-salesclerk-7438

    08/14/2019, 10:13 AM
    yeah, I guess that's probably the key factor here
  • b

    bright-gpu-74537

    08/14/2019, 10:14 AM
    wonder if virtual lists are the same
1...959697...1687Latest