Search results for

“column”

2,085 results found

Post

Replies

Boosts

Views

Activity

Reply to swipeActions on macOS?
I have to admit though, I'm still a bit curious about why this doesn't seem to work for me in a two-column layout. The Messages app on macOS is an example of a swipe action occurring without having three columns. So, I'm still not certain about the conditions under which the .swipeAction modifier will work.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Aug ’21
Reply to Filling in a MTLAccelerationStructureInstanceDescriptor
The compiler errors generally warn me that MTLPackedFloat4x3 has no subscripts. Columns in MTLPackedFloat4x3 are represented as a fixed-sized C-array, and imported into Swift as a tuple. So, you need to access each column by tuple member access like .0, .1, .2 or .3. Or else access whole columns as a tuple. I would do it in this way. First, prepare an initializer taking SIMD matrix. extension MTLPackedFloat4x3 { ttinit(_ mat4x4: matrix_float4x4) { ttttself.init(columns: ( ttttttMTLPackedFloat3(mat4x4[0]), ttttttMTLPackedFloat3(mat4x4[1]), ttttttMTLPackedFloat3(mat4x4[2]), ttttttMTLPackedFloat3(mat4x4[3]) tttt)) tt} } extension MTLPackedFloat3 { ttinit(_ vec4: simd_float4) { ttttself.init() ttttself.elements = (vec4[0], vec4[1], vec4[2]) tt} } And set whole transformationMatrix at once. anInstanceDescriptorPointer.pointee.transformationMatrix = MTLPackedFloat4x3(aNodeInstance.transform)
Topic: Graphics & Games SubTopic: General Tags:
Jul ’20
Reply to TableView Functions Missing Items
The previous sample is more that what I need. The first sample is what I'm using. The table view is displaying data but the data is going down the left side of the tableView. The data should go across the tableView for 6 sections or columns and begin another row for 6 sections or columns.
Mar ’17
Reply to NSTableView full reload works, partial reload doesn't
This turns out to be either a misunderstanding of, or possibly a bug in, the way DifferenceKit interacts with a view-based, rather than objectValue-based, NSTableView. I was crucially not checking the values with which reloadData(forRowIndexes:columnIndexes) was called, and the columnIndexes passed by DifferenceKit's algorithm were always [0], which was not valid for any visible cells as my first column is hidden, so the methods weren't called. The useful lesson here is that when a tableview's delegate lacks tableView(_:viewFor:row:), a reload to any column reloads the entire row, but once views are specified, the column values become relevant.
Topic: UI Frameworks SubTopic: AppKit Tags:
Jan ’22
Reply to Table view with dynamic content - is it possible?
It's now possible in SwiftUI with TableColumnForEach [1] But don't use it. I tried and I got crashes when reloading data using Observable, I got crashes when changing columns. My app hung and needed killing when switching away from the table view and back. It crashes if there are zero columns. It's also really slow. Unusably so with about 200 rows and 150 columns. I tried with a release build and no difference was noticable. NSTable on the other hand handles everything admirably. [1] https://developer.apple.com/documentation/swiftui/tablecolumnforeach
Topic: UI Frameworks SubTopic: UIKit Tags:
Mar ’25
Reply to Mac Catalyst Getting Unacceptable Window Resizing Performance on macOS Tahoe With Liquid Glass Design
Because Mac Catalyst doesn't provide a great way to control width constraints of Split View controller columns (unlike the more sophisticated NSSplitView) I was proportionally computing a fraction min width/max width in -viewWillLayoutSubviews. For example: say I want to express a max primary column width as fraction. Sidebar can only grow to 1/2 of the Split View controller width we have to use this property: maximumPrimaryColumnWidth But there is no maximumPrimaryColumnFractionWidth property. Hard values for max column width only makes sense IMO if your window isn't resizable (hard min may be fine though so long as the window min width is properly configured). So to express maximumPrimaryColumnWidth as a fraction you have to compute it: (bounds.size.width/2.0). I was doing this in -viewWillLayoutSubviews and it worked fine before Liquid Glass. But apparently doing this with the Liquid Glass design wreaks havoc. Window resizing performance is much better if I take it out of -viewWi
Topic: UI Frameworks SubTopic: UIKit Tags:
Nov ’25
Reply to text context with column-count value is 2 and text-shadow' blur is greater then 0, the second column will be bring down
Howdy! This bug still occurs on Safari. I've put together a codepen demonstrating the issue and its reproducibility on Safari (using latest as of this posting: Version 17.6 (19618.3.11.11.5)) Codepen: https://codepen.io/cubepresser/pen/ExqvzjL I tested this on the latest versions of Chrome, Firefox and Edge. This bug does not occur. Expected behavior is that there should not be an extra line added to the beginning of the second column, third column, etc. Here's some code if that codepen link doesn't work: HTML: 0000000000111111111122222222223333333333 CSS: #example { font-family: monospace; max-width: 20ch; column-count: 2; column-gap: 0; word-break: break-all; line-break: anywhere; text-shadow: 0 0 4px black; }
Topic: Safari & Web SubTopic: General Tags:
Oct ’24
Reply to SwiftUI subview .frame ignored on parent view appear, MacOS
[quote='776126021, pikes, /thread/776126, /profile/pikes'] Is there a better way to handle a collapsing subview in an HSplitView? Why is the .frame not respected? [/quote] Have you checkout out inspector? Since you're using a NavigationSplitView, an inspector would present as a trailing column and by default, trailing column inspectors have their presentation state restored by the framework.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Mar ’25
Reply to Using new UISplitViewController features with Interface Builder/Storyboards
In the storyboard I selected the split view controller and set a run time user defined attribute of style number 2 (for 3 column mode). Then I disconnected the relation segues and instead set storyboard identifiers on them then in code I instantiated then using the identifiers and used the setViewController forColumnType method for each of the 3 columns. To show a new Secondary you can use the showDetail segue but there doesn’t appear a way to use a segue to the Supplementary column. For that use showColumm and it works both when collapsed and separated. It might also be a better idea to use that method for showing the Secondary. I’m hoping they add storyboard support in beta 2.
Jun ’20
Reply to How to get Random number from variable
Hello Claude3:You asked: But, why not fetch all results and then do the random pick ?That is actually what I am doing. However after I have the results, I must pick a random item from that results. The problem is I don't have a sequential index for any of the columns from which to construct the predicate:selector = Int.random(in: 0 ..< x) fetchRequest.predicate = NSPredicate(format: ??? == %@, selector) // ??? should be a column with a set of numbers between 0...<x.
Topic: Programming Languages SubTopic: Swift Tags:
Dec ’19
Reply to swipeActions on macOS?
I have to admit though, I'm still a bit curious about why this doesn't seem to work for me in a two-column layout. The Messages app on macOS is an example of a swipe action occurring without having three columns. So, I'm still not certain about the conditions under which the .swipeAction modifier will work.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Aug ’21
Reply to iOS 10 Photo Authorization (Simulator)
Just add this key into your info.plistNSPhotoLibraryUsageDescriptionand also specify your own string in Value column
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Oct ’16
Reply to Filling in a MTLAccelerationStructureInstanceDescriptor
The compiler errors generally warn me that MTLPackedFloat4x3 has no subscripts. Columns in MTLPackedFloat4x3 are represented as a fixed-sized C-array, and imported into Swift as a tuple. So, you need to access each column by tuple member access like .0, .1, .2 or .3. Or else access whole columns as a tuple. I would do it in this way. First, prepare an initializer taking SIMD matrix. extension MTLPackedFloat4x3 { ttinit(_ mat4x4: matrix_float4x4) { ttttself.init(columns: ( ttttttMTLPackedFloat3(mat4x4[0]), ttttttMTLPackedFloat3(mat4x4[1]), ttttttMTLPackedFloat3(mat4x4[2]), ttttttMTLPackedFloat3(mat4x4[3]) tttt)) tt} } extension MTLPackedFloat3 { ttinit(_ vec4: simd_float4) { ttttself.init() ttttself.elements = (vec4[0], vec4[1], vec4[2]) tt} } And set whole transformationMatrix at once. anInstanceDescriptorPointer.pointee.transformationMatrix = MTLPackedFloat4x3(aNodeInstance.transform)
Topic: Graphics & Games SubTopic: General Tags:
Replies
Boosts
Views
Activity
Jul ’20
Reply to SwiftUI NavigationView force "both panels side by side" split behaviour
According to the following article: https://serialcoder.dev/text-tutorials/swiftui/navigation-view-style-in-swiftui/ Use the columns navigation view style to have two panels side by side on iPhones with screens big enough to show two panels. NavigationView { … } .navigationViewStyle(.columns)
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Mar ’24
Reply to TableView Functions Missing Items
The previous sample is more that what I need. The first sample is what I'm using. The table view is displaying data but the data is going down the left side of the tableView. The data should go across the tableView for 6 sections or columns and begin another row for 6 sections or columns.
Replies
Boosts
Views
Activity
Mar ’17
Reply to NSTableView full reload works, partial reload doesn't
This turns out to be either a misunderstanding of, or possibly a bug in, the way DifferenceKit interacts with a view-based, rather than objectValue-based, NSTableView. I was crucially not checking the values with which reloadData(forRowIndexes:columnIndexes) was called, and the columnIndexes passed by DifferenceKit's algorithm were always [0], which was not valid for any visible cells as my first column is hidden, so the methods weren't called. The useful lesson here is that when a tableview's delegate lacks tableView(_:viewFor:row:), a reload to any column reloads the entire row, but once views are specified, the column values become relevant.
Topic: UI Frameworks SubTopic: AppKit Tags:
Replies
Boosts
Views
Activity
Jan ’22
Reply to Table view with dynamic content - is it possible?
It's now possible in SwiftUI with TableColumnForEach [1] But don't use it. I tried and I got crashes when reloading data using Observable, I got crashes when changing columns. My app hung and needed killing when switching away from the table view and back. It crashes if there are zero columns. It's also really slow. Unusably so with about 200 rows and 150 columns. I tried with a release build and no difference was noticable. NSTable on the other hand handles everything admirably. [1] https://developer.apple.com/documentation/swiftui/tablecolumnforeach
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
Boosts
Views
Activity
Mar ’25
Reply to Mac Catalyst Getting Unacceptable Window Resizing Performance on macOS Tahoe With Liquid Glass Design
Because Mac Catalyst doesn't provide a great way to control width constraints of Split View controller columns (unlike the more sophisticated NSSplitView) I was proportionally computing a fraction min width/max width in -viewWillLayoutSubviews. For example: say I want to express a max primary column width as fraction. Sidebar can only grow to 1/2 of the Split View controller width we have to use this property: maximumPrimaryColumnWidth But there is no maximumPrimaryColumnFractionWidth property. Hard values for max column width only makes sense IMO if your window isn't resizable (hard min may be fine though so long as the window min width is properly configured). So to express maximumPrimaryColumnWidth as a fraction you have to compute it: (bounds.size.width/2.0). I was doing this in -viewWillLayoutSubviews and it worked fine before Liquid Glass. But apparently doing this with the Liquid Glass design wreaks havoc. Window resizing performance is much better if I take it out of -viewWi
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
Boosts
Views
Activity
Nov ’25
Reply to Network Extension Unexpectedly Terminated by iOS
[quote='774113021, maxpe, /thread/774113, /profile/maxpe'] On affected devices, the “Swap Used” column shows very low values (a few MB). [/quote] Where are you seeing this Swap Used column? Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = eskimo + 1 + @ + apple.com
Replies
Boosts
Views
Activity
Feb ’25
Reply to text context with column-count value is 2 and text-shadow' blur is greater then 0, the second column will be bring down
Howdy! This bug still occurs on Safari. I've put together a codepen demonstrating the issue and its reproducibility on Safari (using latest as of this posting: Version 17.6 (19618.3.11.11.5)) Codepen: https://codepen.io/cubepresser/pen/ExqvzjL I tested this on the latest versions of Chrome, Firefox and Edge. This bug does not occur. Expected behavior is that there should not be an extra line added to the beginning of the second column, third column, etc. Here's some code if that codepen link doesn't work: HTML: 0000000000111111111122222222223333333333 CSS: #example { font-family: monospace; max-width: 20ch; column-count: 2; column-gap: 0; word-break: break-all; line-break: anywhere; text-shadow: 0 0 4px black; }
Topic: Safari & Web SubTopic: General Tags:
Replies
Boosts
Views
Activity
Oct ’24
Reply to App Store Connect API get Units by day
Solved, I found the Units column in the zipped report file (csv format).
Replies
Boosts
Views
Activity
Mar ’19
Reply to In UISplitViewController, can I use same viewController as a primary and compact column?
I read in setViewController documentation: You can’t assign a UITabBarController to the primary or supplementary columns.
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
Boosts
Views
Activity
Mar ’23
Reply to SwiftUI subview .frame ignored on parent view appear, MacOS
[quote='776126021, pikes, /thread/776126, /profile/pikes'] Is there a better way to handle a collapsing subview in an HSplitView? Why is the .frame not respected? [/quote] Have you checkout out inspector? Since you're using a NavigationSplitView, an inspector would present as a trailing column and by default, trailing column inspectors have their presentation state restored by the framework.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Mar ’25
Reply to Using new UISplitViewController features with Interface Builder/Storyboards
In the storyboard I selected the split view controller and set a run time user defined attribute of style number 2 (for 3 column mode). Then I disconnected the relation segues and instead set storyboard identifiers on them then in code I instantiated then using the identifiers and used the setViewController forColumnType method for each of the 3 columns. To show a new Secondary you can use the showDetail segue but there doesn’t appear a way to use a segue to the Supplementary column. For that use showColumm and it works both when collapsed and separated. It might also be a better idea to use that method for showing the Secondary. I’m hoping they add storyboard support in beta 2.
Replies
Boosts
Views
Activity
Jun ’20
Reply to How to get Random number from variable
Hello Claude3:You asked: But, why not fetch all results and then do the random pick ?That is actually what I am doing. However after I have the results, I must pick a random item from that results. The problem is I don't have a sequential index for any of the columns from which to construct the predicate:selector = Int.random(in: 0 ..< x) fetchRequest.predicate = NSPredicate(format: ??? == %@, selector) // ??? should be a column with a set of numbers between 0...<x.
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Dec ’19