xCode UIView with UITableView [closed] - xcode

Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 7 years ago.
Improve this question
I'm trying to make an app that has a calendar that takes up about 2/3 of the visible screen, and then under it are events that correspond to the selected day.
Basically it will look something like this: Calendar App
Should I use a UIView for the calendar, and then a UITableView for the corresponding information?
Also, I want the entire page to scroll when users scroll through the events in the tableView (not just the information in the table view). Would I need to wrap the entire page in a scrollView to accomplish this?

You don't need to have a UIScrollView. You can simply hide the calendar (with animation) when the table view scrolls to a certain point.
Another simpler solution is to put your calendar in the first table view cell, so it would scroll along with your events. So this one just requires one UITableView that fills up the whole screen.

Related

How to sort the table in swift using segmented control [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
i want to ask about the methode used to reload a sorted table view instead of reloading the normal one using swift. I know that I have to use the segmented control to represent the categories in the table but what is the logic how is the code ?
I put a picture showing what I mean
Edit: my question was about using two table views in one view controller in swift with segmented control that is used to display the first table when the 0 segment is clicked and the second table when the 1 segment is clicked and I found the answer for any one interested :
1- add two table views to your view controller.
2- make one of them hidden.
3- in viewDidLoad func load both tables and fill their cells.
4- use the segment control to change the hidden property of the first table to true while the other table is false when the first segment is selected and vice versa when the other segment is selected.
hope that helps.
try:
segmentControl create in new UIView and self.tableView.tableHeaderView = newView on viewDidLoad() method.

UIViewController moves when resizing objects on it [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this question
A quick one - I know that this has been asked a number of times but I can't find the answers on here. I have started a new project in Xcode and when I resize objects they resize from the other side of themselves, the controller moves with it etc. I know it is a simple setting somewhere but I can't find it - any helpers?
Your view controller is probably has auto layout enabled. When you resize one view, the others are resized according to their constraints.
To turn off auto layout: Select the view controller in IB, and in the properties pane on the right, open the first tab, and uncheck the Auto Layout checkbox.

The very basics - Hello Image in IOS [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this question
The answer given to How do I create an iPhone app with background and rotating images? says, "then on Interface Builder or the Storyboard, from the Library drag an Image View (also called UIImageView) and place it on your canvas,"
I'm new to IOS. How do I "from the Library drag an Image View"? I've looked around through the interface, and do not see an opening to the Library from which I can drag an Image View. On the LHS of the screen there is a Frameworks folder that lets me select a UIImageView.h and try to drag it (I can't drop it on the storyboard).
How do I navigate to and manipulate the Library in Xcode so I can drag a UIImageView / Image View onto the storyboard?
Hit Cmd+1 to show the project navigator
Select the storyboard file to open it
Hit Ctrl+alt+Cmd+3 to show the object library (appears at the bottom left corner)
look for the Image View item in the list (you can filter the list using the search field)
drag this object into the canvas or the document outline

Is it possible to separate the XAML page into designer and xaml windows? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I am coding up a Windows Phone 7 app and as large as my screen is, I'd like to separate the designer from the XAML coding window and throw it onto another screen.
Possible?
I'm not sure if this is what you want but if you double click on the "XAML" or "Design" tabs in-between the two panes it will maximize that tab and you can then use the tabs to switch back and forth between design view and XAML view.
Hope this helps
Edit: If you want to go back to split pane view there are three very small icons at the bottom right and you can click one of those to either split vertically or horizontally. The one with the double arrows will also let you switch back and forth between single and split pane views.
Edit: I found this on MSDN which makes it seem that they had the split view so that
...if you drag a control from the
Toolbox to Design view, the XAML is
immediately updated to reflect the new
element. Likewise, if a new element is
added by typing the markup in XAML
view, the visual representation will
appear in Design view immediately,
once the XAML is correctly formed.
Edit 3: Looks like someone found an answer before. You may want to try this:
Separating designer from XAML window for WPF in VS2010

Hidden Features of Interface Builder? [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 11 years ago.
Improve this question
What are some uncommon or "hidden" features of Interface Builder you wish you would have known about when first learning Xcode + Interface Builder?
Edit:
Xcode specific tips here.
This question is specifically concerned with the GUI and not so obvious features of Interface Builder. And only tangentially related to Xcode.
Sometimes it gets quite difficult to select an interface element that's buried in a deeply nested hierarchy of other elements (like a cell in a table column in a table view in a scroll view in the content view of a window).
Pressing shift while right-clicking on a view displays a nicely sorted stack of items to select.
You can use the mouse to measure the distance in pixels between interface elements: Select an element, like a button, then hover the mouse over another element and press option. This also works for subviews, like scrollers in a table view.
After customizing a view or building a view hierarchy you can drag that view back to the library to save it in the current state. You give it a name and description. It will show up in a "Custom Objects" section and can be reused in other nibs.
I only found the Xcode User Defaults Reference the other day. It has a good number of things not available in the preferences UI.
Interface builder has plugin architecture for custom views.

Resources