115 questions
0
votes
0
answers
47
views
Why are there so many extra layers in my view hierarchy?
I have a simple app with a login screen. Once you log in, theres a test view that holds "Hello World" Text and nothing else. Its totally functional, but I noticed in the view hierarchy, a ...
0
votes
0
answers
28
views
Error occurs when I use IBOutlet for connection to custom component in iOS 12.5.7
Error occurs when I use IBOutlet for connection to DefaultTextField in iOS 12.5.7. But if I use programmatic application, no error occurs.
This error usually occurs iPhone 6 and iPhone 6 Plus in iOS ...
0
votes
0
answers
47
views
AmbiguousViewMatcherException in instrumented espresso tests matching two views due to filter clause not having the intended effect
I struggle with the implementation of an instrumented test based on androidx and espresso.
I am trying to prepare a ViewInteraction in a generic way, since I require the same in multiple actions ...
0
votes
0
answers
39
views
SwiftUI Why Button label stay at top of view hierarchy?
A partner told me that my popup is overlayed by another views. I checked by view hierarchy and see some button's labels are staying at top of view hierarchy. I am not sure is it the problem.
import ...
0
votes
0
answers
51
views
Is it possible to pass data from the View Hieracrchy to the App Delegate without using a Singleton?
I want to access data that is populated into Environment Objects during the lifetime of my application in my AppDelegate's applicationWillTerminate() function.
I've looked around Stack Overflow and ...
0
votes
2
answers
41
views
what does 【give the child view controller a chance to respond to the change in view ownership】mean?
I know when you add a child view controller to a parent you need to perform the following steps:
Call the addChildViewController: method of your container view controller.
This method tells UIKit ...
0
votes
1
answer
73
views
UIView.animateKeyFrames blocks Uibutton click - view hierarchy issue or nsLayoutConstraint?
I currently have a ToastView class that creates a view that contains a button, label, and image. The goal is to get this ToastView instance to slide up and down on the controller as a subview, like a ...
2
votes
1
answer
234
views
How to find where UIView has been created in code - swift - Programmatically
If I see a UIView in Debug View Hierarchy and I don't know where it comes from,
Is there a way to see where it has been programmatically created in code?
This question describes and explains the ...
0
votes
1
answer
341
views
How to fix UICollectionView - All cells disappear - Xamarin ios
I am using a UICollectionView in C# Xamarin ios and sometimes all of the cells will disappear from the screen. This happens normally on a scroll and I have to re-invoke the view that my UICollection ...
-1
votes
1
answer
439
views
View in simulator has different frame than in View Hierarchy
I have a strange bug where bottom button hides below the screen. The strange thing is that it is actually tappable and in View Hierarchy it displays as it should be. How could this be? How to debug ...
0
votes
1
answer
945
views
Dynamic Creation UIButton AddTarget on UIView executed on UIViewController
Currently this code that executes a Tag Styled List, The issue remains when I want to try to pass the addTarget Action optionClicked to my UIViewController
DrawerView.swift
let menuOptions = ["Info",...
1
vote
1
answer
90
views
UISearchController extra unexpected UIView in hierarchy
I have problem with UISearchController. It is adding one extra View as direct child of its View. It has isAccessibilityElement = true and description "Double-tap to dismiss", this blocks all Appium ...
2
votes
1
answer
1k
views
Xcode View Hierarchy debugger won't rotate views on mouse drag
I'm running Xcode 10.2.1, on MacOS 10.14.3 (Mojave), compiling and running a default single view iOS application in the simulator. When I click on 'Debug View Hierarchy' I can see the views, switch ...
2
votes
2
answers
283
views
Swift - UIPanGestureRecognizer selecting all layers when only want the top layer selected
I have function which creates a drag line to connect 2 buttons to each other. This works fine but if some buttons overlap each other, it will select both if I drag over where they overlap. I only want ...
0
votes
1
answer
74
views
assigning new rootViewController to window doesn't remove current from view Hierarchy when debugging view hierarchy using xcode
old root view controller not removed when assigning new root view controller
i want to reload the app from its beginning ,but i notice that the old root view Controller not removed from view ...
4
votes
1
answer
4k
views
View Debugging: What are the layers of view in any View Controller?
For example, when I add a table view to my view controller what would the view hierarchy be? Is UIWindow always the base View of the hierarchy?
In which layer does the Status Bar lie?
I mostly write ...
0
votes
1
answer
75
views
nil error when attempting to set textfield placeholder, segment uiview
xcode v:9.2
I am trying to load user information from the database to set as placeholder text. I have tested this code on a simpler project that does not have segment views, and it works fine. I did ...
0
votes
1
answer
41
views
Popover on a Popover issue while tap on notification(Deeplink)
I have already presented a controller on the screen and now click on the home button. Then I need to present another controller on that after tapping on notification using deeplink.
When app comes to ...
2
votes
1
answer
587
views
Avoid multiple instance creation of view controller
I have a custom view controller in which I have created a custom navigation bar with multiple buttons.I have used that custom view controller as parent of multiple child controllers(to use that same ...
0
votes
1
answer
3k
views
Auto Layout constraint crashes due to anchor in a "different" view hierarchy in iOS, but
I am working in an iOS 11.X app with Swift 4.1, fully programatic. Using Xcode 9.4
I am trying to have a view centered in the middle (horizontally), with a distance of 10 pts to the top of the view, ...
1
vote
2
answers
1k
views
_UIRemoteView - reveal view hierarchy in Xcode
I'd like to see, how the Apple's UI frameworks are composed, in particular, the ContactsUI. However, when I try to Debug View Hierarchy in Xcode, I see only the blank _UIRemoteView.
Is there any way ...
1
vote
1
answer
2k
views
iOS: How to cover status bar with container view
I have following view hierarchy in my main view controller:
Main view -> Container view -> Page view controller in container view -> Item view controller for every page
I need to make item view ...
1
vote
0
answers
793
views
Container View Controller disappears when Child View Controller presents a Modal View Controller iOS Swift
I'm new to the iOS swift scene and i was hoping you would be able to help me find a solution or send me on an alternative route to achieving this.
Here is the diagram to my Application Interface ...
1
vote
0
answers
159
views
UITabBar change view hierarchy after rotating process. (or changes its position in view hierarchy)
I have a view with several subviews (with only one peculiarity I added tabBar as a subview to a view of VC)
super.viewDidLoad()
view.addSubview((tabBarController?.tabBar)!)
view.addSubview(...
0
votes
1
answer
166
views
(Swift) Switching between UINavigationController and UITabController nested within Main UINavigationController
Through storyboard, the app entry point is a separate UINavigationController that does some logic on user authentication to first determine whether to push the Home view's embedded UITabBarController ...
10
votes
1
answer
5k
views
Embedding a UICollectionView in a UIScrollView works almost perfectly
Background
I embedded a UICollectionView inside of a UIScrollView and it works almost perfectly.
Goal
The scrollable elements should pass off the scroll seamlessly once they've reached the end of ...
6
votes
1
answer
1k
views
What is PGHostedWindow in window hierarcy on iPad and how to prevent their creating?
Ok. Here is the question. I have tabBar controller, in tab at index 0 I have a TableView with cells showing video by AVPlayerViewController. For iPhone, when i print content of UIApplication.shared....
0
votes
2
answers
866
views
Overlap label on imageview inside uistackview ios
I would like to overlap two views (one view on top of each other) inside uistackview . My objective is to display initials of username on top of his image. The image size is constant and the initial ...
6
votes
0
answers
172
views
Exception gathering view hierarchy information -[UITextView _firstBaselineOffsetFromTop] only valid when using auto layout
I'm getting this warning in the console output when i try to debug the view hierarchy in Xcode 9.
Exception gathering view hierarchy information -[UITextView _firstBaselineOffsetFromTop] only ...
7
votes
2
answers
2k
views
Is It Possible To Customise CNContactPickerViewController?
I'm opening a CNContactPickerViewController for use in an application, but I want to alter the way it presents to suit my apps needs, preferably without rolling my own and doing a lot of re-inventing ...
0
votes
0
answers
323
views
Attempt to present <> on <> whose view is not in the window hierarchy
I'm using this code in AppDelegate where on some condition it either opens login screen or splash screen. like below
if (mobile != nil && keepMe == true) { // skip login
let ...
0
votes
1
answer
247
views
How to show a growing sub view over a parent view
I have a view as follows
The colored tiles are basically views. When i long press on the tiled views i am creating a copy of the tile in which it was long pressed. Also when it is long pressed there ...
0
votes
0
answers
398
views
Custom View AddSubview programmatically, not shown UIElements…
I do this to add a Subview from Storyboard, which is a subview from a ViewController with its own Class. (TomStatusbarController) ...it is set as CustomClass in Storyboard. I do also Constraints with ...
1
vote
1
answer
523
views
A TableView that "fits" (ala "sizeToFit") its dynamic cell's content size. Then nested in a parent UIView that is also "sized to fit"
I'm not sure if I'm approaching this in the most optimal way.
(1) First, I want a tableView with an arbitrary number of cells, whose dynamic cell height varies (based on content from web server, ...
2
votes
1
answer
861
views
wkwebview ios 10 stops loading files with localfileurl after recreation of webview
I have a strange behaviour with wkwebview and ios 10.3 and swift 3.
I am using a wkwebview to display local html files (under Application Support).
At first startup everything works and the local ...
0
votes
1
answer
461
views
Material swift : UIView with Searchbar and TabBar moves out of view swift 3
I have SearchBar and TabBar on a view which i created using CosmicMind Swift Material framework for swift (https://github.com/CosmicMind/Material). Below is the code i have for setting up the view:
...
0
votes
1
answer
214
views
Container GUI for 3 different mfc applications
I currently have 3 very similar, but slightly different mfc applications, which would normally be opened at the same time as part of their workflow and usage in a Windows environment. I would like to ...
0
votes
1
answer
80
views
iOS Is it possible/expected for a view controller to outlive its view?
In the app I'm working on, we sometimes get random crashes in the completion part of a network request.
The chain of events is as follows:
Add a view controller as a child VC. The parent is ...
0
votes
2
answers
515
views
How to get which view in the hierarchy was touched?
I have an UIview V of type MyUView, which contains a stackView named S1. The S stack contains a stackview named NM, which contains a UITextField named T and another stackview named M, whose contains ...
9
votes
3
answers
11k
views
How to programmatically set view to the front/back?
I'm working on an application that uses UIViews as backgrounds to text. I've put the views behind the text in the storyboard but for some reason some still seem to be in front of the text. Is there a ...
3
votes
0
answers
525
views
Get a reference to react-native created image views from Objective-C
How do I get a reference to one of the react-native created image views from Objective-C.
I have a basic react native app that I created with the following js code
import React, { Component } from '...
1
vote
1
answer
103
views
View stuck behind MapView
I have tried everything to make my view appear over the map view (see code below), but it still won't show up. I don't know what to do. This is the mapView at 0.5 alpha
segmentedControl = ...
0
votes
0
answers
46
views
hide a button on checking a condition while the app enters foreground
I have to hide a button by checking two particular viewcontroller's view is a descendant of present view.This is being done when the app comes to foreground.
Code:
[[NSNotificationCenter ...
0
votes
1
answer
714
views
How to show view controller from custom UIButton class?
I have following view hierarchy: navigation controller, inside it I pushed another view controller which contains UITableView with custom UIButtons in the cells. I have another view controller (...
0
votes
2
answers
105
views
pick up custom views in UIView hierarchy
There is a situation that should select all custom view(not system view type such as UILabel or UIButton etc.) like XXButton or XXView. How can I iterate a UIView's subviews to figure out all the ...
0
votes
1
answer
57
views
Placing a view directly on top of another of the same size
Ok, first what i'm trying to achieve:
A background video with interactive text over the top.
This text is being generated in the code i've written and is being presented in a UIView. The video is ...
2
votes
1
answer
2k
views
Root View Controller's view not in the Window Hierarchy
I have coded a login page which in my app delegate (under the method application:didFinishLaunchingWithOptions:) is set to be my root view controller with
[self.window setRootViewController:vc];
...
1
vote
1
answer
57
views
Want dark color of button placed on transparent layer [duplicate]
I have one transparent layer on my controller with imageview on it. Now when I put the button with image it shows transparency. Though I make the alpha set to 1 on button and I also know the button ...
1
vote
0
answers
678
views
Swift: Reset a View Controller within a View Hierarchy
I am trying to completely reset Game when Endgame Screen is dismissed and the view goes back to Game. I have tried dismissing Game but it also get rids of EndgameScreen. I have even gone as far as ...
0
votes
1
answer
208
views
"whose view is not in view hierarchy" on Segue
I try to perform a segue programatically from one view to another, way after it's been loaded (server sends an order to proceed) but it won't happen because "whose view is not in view hierarchy". Any ...