infinitered / redpotion

We believe iPhone development should be clean, scalable, and fast with a language that developers not only enjoy, but actively choose. With the advent of Ruby for iPhone development the RubyMotion community has combined and tested the most active and powerful gems into a single package called RedPotion
MIT License
233 stars 40 forks source link

When I set navbar translucent to false grid stops working #162

Closed dkrusenstrahle closed 8 years ago

dkrusenstrahle commented 8 years ago

Hello,

When I set navbar translucent to false grid stops working. The grid is there but the UIViews that I have placed on first row is on third row if translucent is set to false (when true all is fine).

I tried this in both apperance.rb and style sheets.

UINavigationBar.appearance.translucent = false

UINavigationBar.appearance.tap do |o|
        o.barTintColor = rmq.color.black
        o.setTintColor rmq.color.white
        o.translucent = false

        o.setTitleTextAttributes( {
          UITextAttributeFont => rmq.font.medium,
          UITextAttributeTextColor => rmq.color.white
        })
      end

This seems to be a serious bug since I cannot even use a background image without disturbing the grid.

Base view when translucent is set to true

UIView ( root_view ) 4487615040 {l: 0, t: 0, w: 375, h: 603}

simulator screen shot 28 mars 2016 12 44 53

Base view when translucent is set to false

UIView ( root_view ) 4487615040 {l: 0, t: 64, w: 375, h: 603}

simulator screen shot 28 mars 2016 12 44 18

What is wrong? Please help. Redpotion is a seriously cool tool but me (and I guess many with me) cannot use it until this bug is fixed.

Thanks!

dkrusenstrahle commented 8 years ago

Any solution to this?

GantMan commented 8 years ago

hey @dkrusenstrahle ! This seems like a pretty easy fix from the description. Unfortunately we're overflowing right now. I'll raise a flag inside the ship and see if I can charm someone into taking a look at it. Might be a good opportunity for you to add your name to the contributors list! Have you checked the source on the translucent property?

dkrusenstrahle commented 8 years ago

@GantMan would be very very nice if this bug was fixed. Pretty blocking :) I have unfortunately no idea how to solve it so it would be awesome if you could take a look at it, I am sure I am not the only one suffering from this bug :) Thanks!

jamonholmgren commented 8 years ago

@dkrusenstrahle I'd recommend not using the grid -- it's been in more of an "experimental" phase for a while. I'd use RMQ's frame-based layout instead.

squidpunch commented 8 years ago

@dkrusenstrahle I dont think its actually based on the grid layout specifically -

def on_load
  self.edgesForExtendedLayout = UIRectEdgeNone
end

I think this should put your root view back to zero (maybe?)