xAP Flash nee Joggler beta 5

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • Kevin
    Moderator
    • Jan 2004
    • 558

    #61
    Originally posted by BodgeIT View Post
    Hi Kevin,
    Yes I deleted post because I started to understand the logic of the override, although I still don't like it.
    It's like a perverse logic and takes a bit of getting used to.
    Once I saw it's purpose I decided not to comment.
    The real purpose within config.xml is to allow you to say take someone else xapconfig.xml and change a black button theme to a red button theme or perhaps change label sizes time stamps or complete button styles without having to alter their XML. It's not ideal but it does go some way towards this. Overrides within pages are useful to set a page style too - eg larger red or 50% transparent buttons on this page only..

    I get that page defaults to location 0,0 and that all we can do is move a "sized" background around that page using <posY><posX>. At the moment I'm trying to use this as a highlighting background to group my buttons. I just can't get the background to show on the page.
    You can have multiple backgrounds on one page should you wish - in a way the background is like a textbox that can display an image. Buttons sit on top of backgrounds - and textboxes on top of buttons in the display order. The highlighting background 'container' is an ideal application for backgrounds as it makes pages look like pop up sub pages. Although not very apparent as it's black on black, if you look in the getting started doc towards the end then the 'lighting' 'heating' 'security' and 'amplifier' use this - easiest to see on the lighting screenshot.

    I'm expecting the above script to drop my background
    onto the screen into position 0,0. I was then going to move it to the correct position. I just don't see the background.
    You need to add some tags within the <background> section. The tags need to be <posX> <posY> <width> <height>.

    <posX> and <posY> within <background> will likely default to 0 but probably <width> and <height> are too as there are no <defaults> available for <background>.

    The existing <width> and <height> tags you have included are at the <page> level - and so set the page width/height - not the background. A page currently always defaults to position 0,0 and occupies the full width and height of the screen so these pos tags are not currently used.


    <background>
    <image>back-control.jpg</image>
    <visible>true</visible>
    <posX>175</posX>
    <posY>70</posY>
    <width>225</width>
    <height>225</height>
    </background>

    I remember you mentioning about setting defaults and that if they weren't set, that items could disappear but I have a default for the background set.
    It is not possible to set defaults for backgrounds currently... so <width> and <height> are probably defaulting to 0 causing the background image to be invisible.

    It seems the moment you add <alpha> to the page, all buttons are affected although this may only be in effect when a <group> tag is used.
    This is where I feel the current override logic simply fails and yet I get it works...wierd.
    An <alpha> tag at the page level will make that page (and therefore all its contents) have transparency. If you want specific buttons, backgrounds or textboxes to have transparency then add the <alpha> tag within their specific elements. Having something like..

    <defaults>
    <button>
    <alpha>

    ....would be the way to create a default button transparency - either within <overrides> , within <layout> or within a <page> depending on the intended scope of the defaults. You could also include an <alpha> tag within any specific <button> that you didn't want to take the default value.

    This requires those extra <defaults> features - and the <alpha> default - as I said before... hopefully in the next beta, but that's on Martyn's todo list.

    The tag spreadsheet is a really good cross reference of the validity of the tags at the various nested levels... I will be reposting an updated one but it is pretty good for sorting out things like the above....

    I know example enhanced XML files would help too....

    K
    Last edited by Kevin; 25 September 2010, 03:54 AM.

    Comment

    • Kevin
      Moderator
      • Jan 2004
      • 558

      #62
      Originally posted by BodgeIT View Post
      Here's my latest screen. going for a carbon fibre look. I'll be creating some appropriate buttons as soon as I can.
      Looks good - The internal buttons are Flash movieclips and currently have a 10 state display based on the timeline position. This isn't an ideal model going forward due to the permutation issues when providing more icons so eventually it will be change. It was a wrong path I took earlier.

      xAP Flash can import these SWF Flash buttons and use them just like the internal ones but for speed reasons they're better if they are internal in the library so I welcome submissions of button designs that we can include.

      If you use standard button images (gif, png, jpg etc) then currently only single or dual (on/off) state images are supported. We will eventually support 4 state which will include the 'unknown' and 'error' states and maybe more (blank - no icon - or dimmed for example).

      If anyone want's one of the internal buttons as a Flash .SWA source example - to adapt and create new buttons / change colour etc - just holler. You will need Flash to edit it.

      K

      Comment

      • BodgeIT
        Automated Home Sr Member
        • Jul 2010
        • 57

        #63
        Thanks for all that Kevin, that's cleared a lot up.

        Feature request: Borders for backgrounds.

        Something I noticed the other day, is when testing on the browser, my mute button from my Slimp3 works as expected but doesn't on the Joggler.

        It's a simple button sending a Xap message to my Slimp3:

        <button NAME="Mute">
        <gridX>1</gridX>
        <gridY>2</gridY>
        <posY>-20</posY>
        <visible>true</visible>
        <xAP>
        <schema>xAPBSC</schema>
        <uid>FF.0CDEB609:0001</uid>
        <source>ersp.SlimServer.Peapod:Kitchen</source>
        <on>
        xap-header
        {
        v=13
        hop=1
        uid=FF.0737:0000
        class=xAPBSC.cmd
        source=UKUSA.xAPFlash.test5
        target=ersp.SlimServer.Peapod:Kitchen
        }
        output.state.1
        {
        ID=*
        Level=0/100
        }
        </on>
        <off>
        xap-header
        {
        v=13
        hop=1
        uid=FF.0737:0000
        class=xAPBSC.cmd
        source=UKUSA.xAPFlash.test5
        target=ersp.SlimServer.Peapod:Kitchen
        }
        output.state.1
        {
        ID=*
        Level=33/100
        }
        </off>
        </xAP>
        <mode>toggle</mode>
        </button>

        In the browser it simply muted and unmuted but in the Joggler it seemed to have 3 modes.

        1. Sets current volume back to the default volume.
        2. Mutes
        3. Unmutes

        While checking and testing it, it started to work on the joggler too and I thought "the only thing I've done was to reboot after upgrade", so I thought it must have been fixed in 5d. I rebooted and checked again and it's gone back to having 3 modes. Also the volume slider shows the level as a value, which it doesn't in the browser.


        Something else I noticed is just how often I'm tempted to prod my laptop screen when testing changes in the browser.
        Last edited by BodgeIT; 25 September 2010, 11:38 AM.

        Comment

        • Kevin
          Moderator
          • Jan 2004
          • 558

          #64
          Originally posted by Kevin View Post
          The tag spreadsheet is a really good cross reference of the validity of the tags at the various nested levels... I will be reposting an updated one but it is pretty good for sorting out things like the above....
          I received an email question re how to use the spreadsheet - so I just wanted to clarify....

          Across the top the columns are divided into the two files config.xml and xapconfig.xml, and within each of these there is a hierarchy of tag depths - so for example column 'O' pertains to the <page><textbox>elements within xapconfig.xml.

          If you scan down this column it tells you which tags can be included at this depth. So for example a <background> element can be included but only tags <visible> and <colour> can be included within that. If you were setting the <mode> for a textbox then only 'text' and 'displaytext' are valid.

          Some tags eg <posX> are usable within sub elements or at root levels (root level is column D and sub elements are shown in E and F).

          K

          Comment

          • Kevin
            Moderator
            • Jan 2004
            • 558

            #65
            Originally posted by BodgeIT View Post
            Feature request: Borders for backgrounds.
            I am not sure I can do that as there is no .border property available on the loader object that is used here - I'll take a look. Instead you could create a page with a textbox that had a border and an image loaded and then add another page on top of it - mostly transparent so the previous page's text box is visible but is now behind the buttons.

            Something I noticed the other day, is when testing on the browser, my mute button from my Slimp3 works as expected but doesn't on the Joggler.
            The effect of a button can only be a consequence of the xAP message content so xFX Viewer is the path to see if things are weird here.... however...

            It is easy to get different versions of the xapconfig.xml file in use. You can share your xapconfig.xml between both the browser and Joggler so you are certain you are using identical files. Also ensure xAP Flash is restarted to pick up new files - it only parses the XML at startup.

            Your xAPBSC.cmd messages do not include a state=on / state=off command and I just need to explain the consequences of that as it relates to light dimmers too. It's easier to visualise for that too so bear with me..

            ... The state of a light is either on or off - regard that as whether power is available. The level is the brightness and can be 0-100% (or a specific level eg level=178/255). These two aspects are totally independent i.e. you can have a light that is ON but is at 0% (so looks like it is off) or you can have a light that is off but the level is at 60% (so it still looks off as no 'power' is available). This is done to allow the level to be remembered when a light is turned off, so a light returns to the last level when turned back on. Or indeed whilst the light is off you can change the level so that the next time it is turned on it comes on at that new level.

            Using sliders - this has consequences . Ensure your light is on before you change a slider level, as otherwise you are just changing the 'stored' memory level ie the level at which the light will next come on at. You could of course send a state=on when the slider is opened if you always want it to be on.

            The key thing you should gather for your Slimp3 is that sending Level=0/33 will always take the volume down to nil (mute) but it doesn't turn the Slimp3 off. Sending level=33/100 will always restore the volume but it doesn't turn the Slimp3 on if it was off. It will work as you expect if the Slimp3 was on however. So you might perceive there to be three states. You can modify your level=33/100 to include a state=on command to ensure this always works.

            Something else I noticed is just how often I'm tempted to prod my laptop screen when testing changes in the browser.
            Yes - you should see the number of fingerprints on my monitor - worse still some of my monitors are touchscreens and some aren't so very confusing. On a PC you have extra visual element interaction options too - for example mouse enter/leave/over - which you can't use sucessfully on a touchscreen.

            K

            Comment

            • Kevin
              Moderator
              • Jan 2004
              • 558

              #66
              Originally posted by Kevin View Post
              I have looked at but so far been unable to remedy the textBox font display issue on a Joggler client.
              I have established that the font is being substituted and that to display a similar font I need to force it to bold. This I will do when the textbox is being displayed on a Joggler (only). Displaying other fonts than Verdana might produce unpredicatable results on a Joggler as I can't find any info as to which fonts are resident on it. I had expected Verdana and Frutiger.

              Later when I can get the font embedding working this might not be fully resolved.

              K

              Comment

              • BodgeIT
                Automated Home Sr Member
                • Jul 2010
                • 57

                #67
                Great Kevin, thank you.

                Comment

                • Kevin
                  Moderator
                  • Jan 2004
                  • 558

                  #68
                  Beta 5e (pre) is quite a bit of an update to the code supporting a totally reworked XML tag recovery mechanism and all the appropriate defaulting. It may well change the layout of your screens but hopefully only because it is using the correct defaults now. Martyn has been working really hard on this and it will be available shortly.

                  Hopefully 0.5e should be the last of the pre releases and then, assuming the feedback is OK, I'll post it as the official beta 5. Please let me know ASAP if you find other bugs.

                  Anyone new wanting to be on the beta test for the beta 5 release let me know...

                  K
                  Last edited by Kevin; 30 September 2010, 01:58 AM.

                  Comment

                  • Kevin
                    Moderator
                    • Jan 2004
                    • 558

                    #69
                    Resident Fonts in Joggler

                    Originally posted by Kevin View Post
                    ....as I can't find any info as to which fonts are resident on it. I had expected Verdana and Frutiger.
                    ... and oh how wrong I was !

                    I've had a bit more of a look at the Joggler font issue. I still haven't sussed the Flash embedded fonts but I have managed to get a list of the fonts that are available on the Joggler - sorry, for a very obscure reason it's an image file at the moment. (attached - right click to download a copy)

                    Gary... If you try using say FreeSans as a font in html it may well look better for you. They are a rather weird set of fonts and I haven't had time to look through what is available. Nearest font substitution doesn't seem to work well from the better known families.

                    Although say Verdana is listed as Flash embedded - it still isn't working as a displayable font in text boxes, so only use the 'device' fonts.

                    K

                    PS This will be a good use of the <override><defaults> feature using config.xml as you can create a standard xapconfig.xml file whilst on your PC but then override the font family in use within textboxes when the same (unchanged) file is loaded on your Joggler. The dual font name approach that your previous html example used should work too.

                    Last edited by Kevin; 30 September 2010, 02:09 AM.

                    Comment

                    • SiliconPixel
                      Automated Home Sr Member
                      • May 2007
                      • 52

                      #70
                      Hi K,

                      Can you please add me to the beta 5 list if I'm not on it.

                      Many thanks,

                      Paul.

                      Comment

                      • Kevin
                        Moderator
                        • Jan 2004
                        • 558

                        #71
                        I have posted pre beta 5e - Assuming there is no adverse feedback this will be the last prerelease version and we shall then move to a general release of beta 5 to all those who are interested.

                        Martyn has worked really hard on this version and there has been a lot of changes to the way in which we recover tags from the XML. Inparticular all the defaults are now implemented for all relevent element tags - so if you omit tags, or leave them blank then they will pickup a default value. (See next post)

                        If your screen layouts change after installing this update then please carefully consider the default values and if you still feel that something is not displaying as expected then post and let us know. We'll need the config.xml and xapconfig.xml file too along with a description of what you feel is wrong.

                        Changes in pre beta 5e

                        XML tag recovery internals changed

                        Defaults for all elements now implemented in all sections

                        Pressing xAP button will now list missing xAP BSC devices (early implementation).

                        xAP button should now be defined using the 'function' mode, note the capitalisation of the <Function> tag name. The previous <mode>text</mode> NAME="xAP" still works but will be deprecated in the next beta (beta 5).
                        <mode>function</mode>
                        <Function>
                        <type>xAP</type>
                        </Function>
                        The 'config' screen has been renamed 'layout' as this is more appropriate. It is also now defined using a function mode. The older <mode>config</config> still works but will be deprecated in beta 5.
                        <mode>function</mode>
                        <Function>
                        <type>layout</type>
                        </Function>

                        In the layout screen (was config) overlapping markers now display a circle marker which cascades the hidden underlying markers when clicked.

                        K

                        Comment

                        • BodgeIT
                          Automated Home Sr Member
                          • Jul 2010
                          • 57

                          #72
                          Great Job Kevin and thanks for all your hard work. Time for a sit down, but before you do that, can I get my grubby paws on the excel xml sheet?

                          ** Edit **
                          Just installed, made changes as reported and xAPFlash boots up blank on Joggler, fine on Chrome. Will take a little time to go through overrides.
                          Last edited by BodgeIT; 2 October 2010, 12:23 PM.

                          Comment

                          • Kevin
                            Moderator
                            • Jan 2004
                            • 558

                            #73
                            Default Element Values

                            There are various defaults implemented for element tag values that are used if the tags are absent or left blank. Here is the order in which they will be applied with the highest priority (1) at the top.

                            1) A tag within the element itself
                            2) A tag within the elements <page><defaults>
                            3) The <override><layout> section within xapconfig.xml
                            4) The <layout> section within xapconfig.xml
                            5) The <layout> section within config.xml
                            6) Inbuilt defaults.

                            You don't (shouldn't) need to include defaults at any levels that you aren't wishing to use.. for example you could omit 1-3 and 5 and use the defaults from the <layout> section within xapconfig.xml

                            Here's the start of a list...
                            Defaults are configurable for the following elements, there are few more more - I'm sure Martyn will update me and then I'll update this post too, I'll also add the inbuilt defaults in brackets

                            textbox
                            width (92)
                            height (92)
                            fontsize (14)
                            fontcolour (0xFFFFFF white)
                            font (Verdana)
                            align (left)
                            alpha (1.0)
                            button
                            style (black)
                            width (92)
                            height (92)
                            alpha (1.0)
                            bsctext (within buttons)
                            font* (currently fixed - Verdana)
                            fontsize (14)
                            fontcolour 0xFFFFCC (pale yellow - may be changed to white)
                            alpha (1.0)
                            label
                            font* (currently fixed - Verdana)
                            fontsize (14)
                            fontcolour (0xFFFFFF white)
                            offset (0)
                            alpha (1.0)
                            time (time stamps)
                            font* (currently fixed - Verdana)
                            fontsize (14)
                            fontcolour (0xFFFFCC pale yellow - may be changed to white)
                            show (true)
                            alpha(1.0)

                            *Note the font within time stamps, labels and bsctext boxes is fixed as Verdana. You can of course replace button name labels and bsctext overlays with your own text boxes for which you can sue any font so that shouldn't be an issue.

                            There are also some non configurable layout related defaults that can only be overidden within individual elements.... and most numeric tags , absent or blank will default to 0.
                            e.g

                            visible (true)
                            posX (0)
                            posY (0)
                            gridX (0)
                            gridY (0)

                            A relative +/- pixel nudge can be applied to grid placed elements if both tags are present and posX or posY are signed . However if posX/posY is present and unsigned then gridX/gridY respectively will be ignored as pos takes precedence over grid.


                            and some layout defaults

                            gridXmax (6)
                            gridYmax (6)
                            marginleft (150
                            marginright (15)
                            margintop (15)
                            marginbottom (15)
                            screenwidth (800)
                            screenheight (410)


                            K
                            Last edited by Kevin; 3 October 2010, 03:11 PM.

                            Comment

                            • Kevin
                              Moderator
                              • Jan 2004
                              • 558

                              #74
                              Originally posted by BodgeIT View Post
                              Great Job Kevin and thanks for all your hard work. Time for a sit down, but before you do that, can I get my grubby paws on the excel xml sheet?

                              ** Edit **
                              Just installed, made changes as reported and xAPFlash boots up blank on Joggler, fine on Chrome. Will take a little time to go through overrides.
                              The latest tag spreadsheet version can be downloaded here


                              If you don't sort your Joggler load issue then let me know (providing the two config files) - remember you have to reboot Jogglers for application update (not data) files to be recognised. If it loads in a browser it should load on the Joggler.

                              K

                              Comment

                              • BodgeIT
                                Automated Home Sr Member
                                • Jul 2010
                                • 57

                                #75
                                Originally posted by Kevin View Post
                                remember you have to reboot Jogglers
                                Hmm, yeah I remembered that after my last issue...have now disabled all the overrides in the config.xml. I'll keep picking it apart...
                                Last edited by BodgeIT; 2 October 2010, 02:45 PM. Reason: spell

                                Comment

                                Working...
                                X