Search results for

column

2,071 results found

Post

Replies

Boosts

Views

Activity

Reply to Creating Floor Plan with RoomPlan
actually what you need to do is remove the y component and not the z component, if you want to convert from 3D->2D, from CapturedRoom you get dimensions.x (wall length) and (transform) .columns.3.x, transform .columns.3.z) is the coordinate of the center of the wall and the direction(transform.columns.0.z, transform.columns.0.z), is the direction of the wall, now you there is a starting and ending point of a wall, similar to other things
Topic: Spatial Computing SubTopic: ARKit Tags:
Mar ’23
Reply to TabularData Framework: DataFrame as a List in SwiftUI
Here's a working example for Mac OS (but should be the same for iOS except for the URL setup for the incoming csv file). The csv test data are in 3 columns, with headers of Name, Position and Score - so as to test data types of String, Integer and Double. The Data Model (ViewModel) import Foundation import TabularData class DataModel { static let shared = DataModel() @Published var dataTable: DataFrame? init() { getData() } func getData() { var url: URL? do { url = try FileManager.default.url(for: FileManager.SearchPathDirectory.downloadsDirectory, in: FileManager.SearchPathDomainMask.userDomainMask, appropriateFor: nil, create: true) } catch{ print(Failed to get Downsloads URL (error)) return } let csvOptions = CSVReadingOptions(hasHeaderRow: true, ignoresEmptyLines: true, delimiter: ,) let fileURL = url?.appendingPathComponent(TestCSV.csv) do { dataTable = try DataFrame(contentsOfCSVFile: fileURL!,columns: nil, rows: nil, types: [Name:CSVType.string,Position:CSVType.integer,Score:CSVType.d
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Mar ’22
Reply to UITabBarController as secondary controller in UISplitViewController is producing 2 navigation bars in compact view
When using the column based split view controller, it presumes that clients want a navigation controller in each of its non-compact columns and will wrap a view controller in one of not provided. This is primarily so that collapsing (when it moves from multiple to single column) behaves deterministically and automatically. So what is happening is you're getting a tab bar controller wrapped in a navigation controller with additional navigation controllers inside – and thus double navigation bars. Realistically this may be a case where you want to create your own custom view controller container instead of using UISplitViewController, as I'm not sure how many of the edge cases you would hit might be resolved.
Topic: UI Frameworks SubTopic: UIKit Tags:
Oct ’23
Reply to UITabBarController is unsupported as viewController
I just ran into this too. The way I was able to get around it was to edit the SplitViewController in the storyboard and set the Style to 'Unspecified'. I think this is the 'classic' mode for SplitViewControllers, as opposed to the 2-column vs 3-column styles that Apple is now encouraging. I think maybe the Build For iPad WWDC video explains the roadmap for where SplitViewControllers are going. We will all eventually have to rethink how our UI's work.
Topic: UI Frameworks SubTopic: UIKit Tags:
Nov ’20
Reply to How to remove all columns from NSOutlineView?
I don't understand the question. Under what circumstances would it be useful to get rid of all columns?>> in case the NSOutlineView has an outline table columnThis is not a case in any reasonable sense. The defining feature of an outline view is that is has an outline column.What's the exact error message you got from trying to use removeTableColumn: on the outline column? I wouldn't be surprised (as an unrelated issue) if the error message is incorrect for historical reasons.
Topic: UI Frameworks SubTopic: AppKit Tags:
Sep ’18
Reply to More info on restore state between split and tab hierarchies needed please
For the UISVC behavior: Use the delegate methods, -splitViewController:topColumnForCollapsingToProposedTopColumn: and splitViewController:displayModeForExpandingToProposedDisplayMode: to set up which vc's are displaying the data. Just return the value that's proposed (presuming that's what you want—if you have set a vc for the compact column, the compact column will be proposed for the collapse). If you want to reparent view controllers at that time, be careful. In the long run, it's probably easier to have separate vc instances.
Topic: UI Frameworks SubTopic: General Tags:
Jun ’20
Reply to DATA
You can export a CSV file and have something sort of like this. While that’ll work, if you’re doing anything serious with CSV files I strongly recommend that you check out the TabularData framework. See the code snippet below. Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com import Foundation import TabularData let csv = Aloe Vera, skin healer, Cut from middle, once every three days, cut the leave and use the gel inside for your rash Almond, skin healer, cut the young leaves, daily, soak in water overnight rinse and blend func main() throws { var options = CSVReadingOptions() options.hasHeaderRow = false let frame = try DataFrame.init(csvData: Data(csv.utf8), options: options) print(frame) // ┏━━━┳━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━┳… // ┃ ┃ Column 0 ┃ Column 1 ┃ Column 2 ┃… // ┃ ┃ ┃ ┃ ┃… // ┡━━━╇━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━╇… // │ 0 │ Aloe Vera │ skin
Aug ’22
Reply to How do I create a tableview with a variable number of columns where the extra columns have checkboxes in them?
Your reply was quite helpful and I quit trying to figure how to get bindings working with this. Too much behind the scenes magic wasting my time.Once I knew I was looking for a solution avoiding bindings, I found a couple gems in the TableViewPlayground sample code that I am pretty sure are not explicitly mentioned in the documentation. Below are details of what I had to do to get a tableView operating without bindings, which IMO, is far easier than bindings once you are aware of the process.VERY IMPORTANT KEYS to building View based DATASOURCE TableViews1. USE BASIC UI items (NSButton), NOT NSTableCellView2. Contrary to #1, you can use NSTableCellView for TextFields, imageViews IF... see below.3. Add your basic UI Items directly to the NSTableColumn, delete provided the NSTableCellView.4. Carefully implement tableView:inTableView viewForTableColumn:inTableColumn row:inRow.Maybe (probably) I am blind, but I trusted the default mechanisms in Interface Builder regardingbuilding tables. Well, they are probably a
Topic: UI Frameworks SubTopic: AppKit Tags:
Mar ’17
Reply to Illegal NSTableViewDataSource
You use it here : if let cell = tableView.makeView(withIdentifier: (tableColumn!.identifier), owner: self) as? NSTableCellView {if I have different cell prototypes for each colum, then I create an identifier for each.extension RegistrationReportsViewController: NSTableViewDelegate { func tableView(_ tableView: NSTableView, viewFor tableColumn: NSTableColumn?, row: Int) -> NSView? { if tableColumn == nil { return nil } // Extra safety var cellIdentifier = var cellContent = let registration = fetchedResultsController.fetchedObjects! [row] let column = tableView.tableColumns.firstIndex(of: tableColumn!)! switch column { case 0: cellContent = registration.lastName ?? cellIdentifier = CellIdLastName // The one you give in IB of course case 1: cellContent = registration.firstName ?? cellIdentifier = CellIdFirstName // Take care of uppercases case 2: cellContent = registration.middleName ?? cellIdentifier = CellIdMiddleName default: break } if let cell = tableView.makeView(withIdentifier: N
Topic: Programming Languages SubTopic: Swift Tags:
Jan ’20
Reply to How to use combo box cell in a tableView
I get an error when I added the following statement NSComboBoxCell.delegate = self The error was no delegate member for NSComboBoxCell.. So, I created a new test project which had a single view and a tableView that I added a comboBox to one of the columns without trying to use a datasource, I expected to see Item 1, Item 2 .. etc. in the column, but again nothing. Also, the comboBox is editable. There must be something basic I am missing. Still looking for an example..
Topic: UI Frameworks SubTopic: AppKit Tags:
Mar ’21