Search results for

column

2,061 results found

Post

Replies

Boosts

Views

Activity

Reply to UISplitViewController displays button to change the display mode even when presentsWithGesture = false
This is kinda an edge case? Might be considered a bug. This is specific logic to cover a case where there is a back action and a split view controller which is a fairly rare configuration. We likely forgot about this specific detail when accounting for this configuration. The goal is to ensure that developers don't accidentally prevent access to the primary column of the split view controller, since normally the back action would handle that.
Topic: UI Frameworks SubTopic: UIKit Tags:
Aug ’23
Reply to NavigationSplitView two and three column interfaces in the same app
I work on a predominantly SwiftUI app, but I managed to achieve this using two UISplitViewControllers and contain my SwiftUI views inside that. I basiccally made an outer two column UISplitViewController. The detail view there is a SwiftUI view that either shows one big view or a UIVIewRepresentable that houses another UISplitViewController, depending on sidebar selection. When that inner splitview is shown, I set the outer nav bar to hidden so just the inner splitview's navbar shows. It took a lot of fiddling with the column behaviours to get it to work just right, but it does work. Although once in a while I see crashes when rotating the iPad which may be attributed to SwiftUI trying to deal with two navigation controllers in the two different splitviews. I've also raised FB12586131 to ask that UISplitViewController and NavigationSplitView support proper switching between two and three column modes. All we really need is a way to hide the middle column only.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Aug ’23
Tensor indexing
I have probably found a bug when indexing tensors with tensorflow-metal. It is best demonstrated by the following minimal example: import tensorflow as tf print(tf.constant([[1, 2], [3, 4]], dtype=tf.float32)[..., :2, 1]) The expected result is [2, 4] (i.e. the second column of the matrix) which is what I get when tensorflow-metal is not installed (and on other non-Apple machines), but using tensorflow-metal I get [2, 2] (i.e. the first element of the column is repeated - this also happens if there are more than two rows). The following conditions seem to be necessary in order to trigger this behavior: dtype must be float32; it works correctly with float64, int32 and int64. the sequence of ellipsis (for batch axes), stride (for row), index (for column) is critical; i.e. it does work correctly when the column is also a stride, and it does work if the row is a single number or the full slice :. the indexed tensor does not actually have batch axes (the ellipsis is there becaus
0
0
465
Aug ’23
swiftui offset of scrollable tab is initialized when tab is converting
Hello, Everyone, I'm developing ios app and have a question. one case that screen of my app has multiple tab including each scrollview, when I change tab scroll offset is initialized. Search.Tag is identifiable and id is different each. and FeedListModel is identifiable also. what's the problem, please give me a tip. This is my screenshot and codes. TabView(selection: $model.selected) { ForEach(model.listByTag, id: .key) { (tag, list) in SearchMoreTab( model: model, feedList: list, tag: tag, stickyHeaderHeight: $stickyHeaderHeight, defaultStickyHeaderHeight: defaultStickyHeaderHeight) .tag(tag) } struct SearchMoreTab: View { @ObservedObject var model: SearchMoreModel @ObservedObject var feedList: FeedListModel let tag: Search.Tag @Binding var stickyHeaderHeight: Float let defaultStickyHeaderHeight: Float // scrollableHeight = contentHeight - scrollViewHeight @State var lastScrollOffset: CGFloat = .zero @State var scrollOffset: CGFloat = .zero @State var contentHeight: CGFloat = .zero @State var scrollHeight:
0
0
993
Aug ’23
Reply to I need the Python code for connecting to my Apple appstore sales reports
DEĞERLİ: tommygod size vereceğim kodu kullanabilirsiniz if response.status_code == 200: try: # Yanıtın içeriğini gziple çözme buffer = io.BytesIO(response.content) with gzip.GzipFile(fileobj=buffer) as f: content = f.read().decode('utf-8') # İçeriği DataFrame'e dönüştürme data = [line.split('t') for line in content.split('n') if line] df = pd.DataFrame(data[1:], columns=data[0]) return df except Exception as e: return pd.DataFrame(columns=['Error'], data=[f'İşlem başarısız oldu. Hata: {e}']) else: return pd.DataFrame(columns=['Error'], data=[f'Beklenmeyen durum kodu alındı {response.status_code}: {response.text}']) apple turkiye gelişdirici fırat averbek saygılarımla
Aug ’23
I need the Python code for connecting to my Apple appstore sales reports
I am trying to create an API that connects to the apple app store, I already converted my p8 into a JWT, it works for other appstore information but not sales. Here is what I have so far, this is a mix of a lot of techniques I tried. Can someone give me the full code they use if they do something similar? import requests import json import zlib from io import StringIO Constants API_ENDPOINT = 'https://api.appstoreconnect.apple.com/v1/salesReports' Load JWT token from file with open(My location for my JWT file, r) as file: token = file.read().strip() def get_sales_report(): headers = { 'Authorization': f'Bearer {token}', 'Content-Type': 'application/a-gzip' } params = { 'filter[frequency]': 'DAILY', # For testing purposes, using DAILY frequency 'filter[reportType]': 'SALES', 'filter[vendorNumber]': 'My vendor', 'filter[reportDate]': '2022-08-01' # Sample date for testing } response = requests.get(API_ENDPOINT, headers=headers, params=params) if response.status_code == 200: try: # Decompress the gzipped content
2
0
2.2k
Aug ’23
ScrollView Memory Leaks with Button Style
Hi There, I have found a suspicious memory leak when I use Scroll View, List or anything else to list a View. This is Scroll view with Lazy Grid define: struct TravelingView1: View { var body: some View { ScrollView { LazyVGrid(columns: [GridItem(.flexible())]) { ForEach(0..<10) {_ in Rectangle() .frame(height: 20) } } } .frame(height: 200) } } And Button Style in the View as: struct ScreenView1: View { @ObservedObject var drawRadioButtonViewModel: DrawRadioButtonViewModel1 var body: some View { RadioButton(type: .radioButton, toggle: drawRadioButtonViewModel.isRadioCheck, identifier: Quick Split, radioWidth: 302, action: { [weak drawRadioButtonViewModel] in drawRadioButtonViewModel?.updateToggleCheck() }, label: {}) .offset(x: -CGFloat(100)/2, y: CGFloat(100)) Button(drawRadioButtonViewModel.isRadioCheck ? Checked : Unchecked, action: { [weak drawRadioButtonViewModel] in drawRadioButtonViewModel?.updateToggleCheck() }) .offset(x: -CGFloat(100)/2, y: CGFloat(100) + 30) } } With Button Style as: st
1
0
619
Aug ’23
Reply to Xcode precompiled header problem
A quick glance at the clang documentation on precompiled headers (https://clang.llvm.org/docs/PCHInternals.html) suggests that a precompiled file for C++ should be automatically ignored for C compilations, but… You can specify build settings on a per-source file basis by going to the Build Phases tab of your project and expanding the Compile Sources phase. Select the source files you care about, then double-click (one of the selected rows) under the Compiler Flags column header. The, enter the compiler options you want for those files. Please note that Xcode build settings don't specify inclusion of a PCH directly. Instead, you specify a prefix file, which you can choose to precompile. You might to use a combination of prefix and precompiled settings to get the selectivity you want.
Aug ’23
Reply to SwiftUI Inspector ideal width
In SwiftUI, the inspectorColumnWidth modifier is meant to control the width of an inspector column within a TableView. The ideal parameter of this modifier should set the initial width of the inspector column, and the system should remember the user-adjusted width for subsequent launches. However, in the beta version of SwiftUI you're using, it seems that the ideal width might not be respected on initial launch. Workarounds: While waiting for potential updates or bug fixes from Apple, here are a few workarounds you can consider to achieve your desired behavior: Set Minimum Width to Ideal Width: Since you want to guarantee the initial width while allowing users to reduce the width, you can set the minimum width to the same value as the ideal width. This way, users won't be able to resize the inspector column to a width smaller than the ideal width. This could be a suitable approach if you're okay with users having a fixed minimum width of 550. TableView() .inspector(isPresented: $sta
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Aug ’23
SwiftUI Inspector ideal width
Should this not set the inspector width to 550 every time? TableView() .inspector(isPresented: $state.presented) { InspectorFormView(selection: model[state.selection]) .inspectorColumnWidth(min: 150, ideal: 550, max: 600) } This is almost verbatim from the WWDC video (10161). This ideal parameter will be the size of the column at at first launch, but if the user resizes the inspector, the system will persist that size across launches. Inspector uses the minimum width (150) in every case. How can the ideal width be guaranteed upon initial launch? I could set the minimum to 550, but I'd like the user to be able to reduce the size of the inspector as well ... Thanks much & keep inspecting!🧐 (Sonoma, beta 5 / Xcode beta 6)
1
0
1.3k
Aug ’23
Xcode Extension accessing Current File and Xcode UI integration
For things like linters, formatting tools, and more: We need a good way to inject into the Xcode UI. Can I create a Warning or Error in the buffer/Issue Navigator? Is there an example of how to mark lines/columns with a message/error/warning? Get the current file path or URL object? How can I place a view onto the Xcode source canvas? Like a popover or interactive window.
1
0
815
Aug ’23
Control padding in Table cells
Hi all, I'm working on a SwiftUI app (macOS only) that uses a Table to show contents of a directory. Each Table Cell seems to have a padding / gap which I would like to remove. If you look at the picture, I want the red rectangle to fill the whole cell. Does anybody know how to achieve this? Here's my current code for that column: TableColumn(name, value: .name) { item in HStack { if item.type == .directory { Image(systemName: folder) .frame(width: 14) } else { Text() .frame(width: 14) } Text(item.name) Spacer() } .contentShape(Rectangle()) .gesture(TapGesture(count: 2).onEnded { print(item) doubleClick(path: item.path) }).simultaneousGesture(TapGesture().onEnded { self.selectedFileItem = item.id }) .background(.red) .padding(.all, 0) } I want this to be applied to all columns in the table. I only showed one column as a reference. The table style is .tableStyle(.bordered(alternatesRowBackgrounds: true))
0
0
699
Aug ’23
Trying to understand SQLite step statement
I am learning SQLite queries. I use prepare statement and one or more calls to a step statement. The prepare statement knows the pointer to the database, the UFT8 select statement and the name of the pointer which will point to the complied SQL select statement. The first step call runs the compiled select statement and if data is returned, the first row is made available via column calls. It seems logical to me that the select statement returns all matching rows but if the first step statement only has access to the first row of data, the balance of matching rows must be stored somewhere. Is this the case and if so where are the query results stored? Or is does this work in some other manner?
1
0
567
Aug ’23