Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-25777

iOS: Cannot use semi-transparent bar colors

    Details

    • Type: Bug
    • Status: Closed
    • Priority: None
    • Resolution: Not Our Bug
    • Affects Version/s: Release 7.0.2
    • Fix Version/s: None
    • Component/s: iOS
    • Environment:

      Description

      The barColor property on iOS ignores an alpha channel. Neither a hex value like ‘#22ff0000’ or rgba value work. The bar is always completely opaque. These values work on android. It does work if you set the barColor to ‘transparent’, but that doesn't work for the specified alpha channel (translucent)

      Steps to Reproduce:
      1. Create a new App then run the following test code on an iPhone device or simulator.

      Test Code:

      app.js

      var gradientView = Ti.UI.createView({
          width: Ti.UI.FILL,
          height: 1000,
          top: 0,
          backgroundGradient: {
              type: 'linear',
              startPoint: { x: '0%', y: '50%' },
              endPoint: { x: '100%', y: '50%' },
              colors: [ { color: 'red', offset: 0.0}, { color: 'blue', offset: 0.25 }, { color: 'red', offset: 1.0 } ]
          }
      });
       
      var win = Ti.UI.createWindow({
          title: 'This bar should be transparent',
          barColor: 'rgba(255,255,255,0.1)',
          includeOpaqueBars: true,
          translucent: true,
          extendEdges: [Ti.UI.EXTEND_EDGE_TOP]
      });
       
      win.add(gradientView);
       
      var navWin = Ti.UI.iOS.createNavigationWindow({
         window: win
      });
       
      navWin.open();
      

      Expected Behaviour: The bar color should be translucent because of alpha channel.
      Actual Behaviour: The bar color is completely opaque.

      Thanks

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                morahman Motiur Rahman
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

                  • Titanium SDK/CLI <> Titanium Mobile
                    Synced with:
                    TIMOB-6179
                    Sync status:
                    ERROR
                    Last received:
                    Last sent:

                    Git Source Code