admaDIC App Development & IT Solutions

Welcome to admaDIC's Development Site

Swift Foundation Models: Chat Swift Foundation Models: Chat

by Annett Schwarze | 2025-06-20

Apple's Foundation Models Framework provides simple access to language models. The sample below shows, how to use a `LanguageModelSession` to send a message and react to a stream of responses.

The feature has been tested on a MacBook with Silicon processor, macOS 26 Tahoe beta and Xcode 26 beta..

[more ...]

Details...

Swift Networking Simple Request Swift Networking Simple Request

by Annett Schwarze | 2025-06-13

Performing network communication in Swift is enabled using URLSession. A very simple request can be implemented with the asynchronous method `data(from: URL)` using just a couple of code lines.

For easy testing the Python package FastAPI provides a very simple and quick means. That way handling network requests can be tested in the simulator while the server can be started on the developer computer.

[more ...]

Details...

SwiftUI Scatter Charts SwiftUI Scatter Charts

by Annett Schwarze | 2025-06-06

SwiftUI Charts support creating scatter charts. To create a scatter chart, use a `Chart` view and place `PointMark`s or `LineMark`s inside.

[more ...]

Details...

SwiftUI Bar Charts SwiftUI Bar Charts

by Annett Schwarze | 2025-05-30

SwiftUI Charts support creating bar charts. To create a bar chart, use a `Chart` view and place `BarMark`s inside.

[more ...]

Details...

SwiftUI Pie Charts SwiftUI Pie Charts

by Annett Schwarze | 2025-05-23

SwiftUI Charts support creating pie charts since iOS 17. To create a pie chart, use a Chart view and place SectorMarks inside..

[more ...]

Details...

SwiftUI Custom Circular Layout Custom Circular Layout

by Annett Schwarze | 2025-05-16

Custom layouts in SwiftUI are provided using the protocol `Layout`. The `Layout` protocol requires to implement two methods `func sizeThatFits(proposal: ProposedViewSize, subviews: Subviews, cache: inout ()) -> CGSize` and `func placeSubviews(in bounds: CGRect, proposal: ProposedViewSize, subviews: Subviews, cache: inout ())`.

[more ...]

Details...

SwiftUI Filtered Table Filtered Table

by Annett Schwarze | 2025-05-09

A Table in SwiftUI is used to present data in rows and columns.

To create a table insert a Table view and nested in there TableColumns. Table data can be filtered and the table will update automatically. However, the filter process itself must be implemented by the developer.

 

[more ...]

Details...

SwiftUI Hierarchical Table Hierarchical Table

by Annett Schwarze | 2025-05-02

A Table in SwiftUI is used to present data in rows and columns. It can display hierarchical data and can be used as a tree view.

To create a table insert a Table view and nested in there TableColumns. To provide hierarchy, add a property to return the children or nil to the data record type and specify its keypath when configuring the Table.

 

[more ...]

Details...

Apple Intelligence ImagePlayground ImagePlayground

by Annett Schwarze | 2025-04-25

ImagePlayground is an AI based image generation tool powered by Apple Intelligence.

To use ImagePlayground in SwiftUI a system sheet can be opened using the view modifier `.imagePlaygroundSheet(isPresented:,concept:,onCompletion:...)`. The feature is available since iOS 18.1.

 

[more ...]

Details...

SwiftUI Transition Transition

by Annett Schwarze | 2025-04-04

Create custom transitions in SwiftUI using the protocol Transition using view modifiers .scaleEffect, .opacity, .rotationEffect, .blur and others.

 

[more ...]

Details...

SwiftUI MeshGradient MeshGradient

by Annett Schwarze | 2025-03-28

SwiftUI MeshGradients offer complex gradients aligned with a grid.

 

[more ...]

Details...

SwiftUI Scroll Effects Scroll Effects

by Annett Schwarze | 2025-03-14

ScrollViews in SwiftUI can be enhanced with scroll effects. To add scroll effects the view modifier .scrollTransition is available. The sample below shows offset effects and rotation effects.

 

[more ...]

Details...

SwiftUI Animations Animation

by Annett Schwarze | 2025-03-14

Basic Animations in SwiftUI can easily be created using state variables and adjusting them within withAnimation blocks. In this example a view's offset is controlled using a drag gesture. When dragging exceeds a threshold, a new animation is started.

 

[more ...]

Details...

SwiftUI Table Table

by Annett Schwarze | 2025-03-07

A Table in SwiftUI is used to present data in rows and columns. It provides features for sorting, selection and more.

To create a table insert a Table view and nested in there TableColumns.

 

[more ...]

Details...

SwiftUI NavigationSplitView NavigationSplitView

by Annett Schwarze | 2025-02-28

NavigationSplitViews can be used with two or three column layout. Selections are managed with NavigationLink(value:,label:) and navigationDestination(for:,destination:). The call to navigationDestination has to be placed in a superview of the NavigationLinks. The destination views of the navigation destinations will be inserted in the next-level container. This may be content or detail.

 

[more ...]

Details...

SwiftUI ColorPicker ColorPicker

by Annett Schwarze | 2025-02-21

A `ColorPicker` is a standard component to select a color. Use it by adding `ColorPicker` and give it a binding to a `Color` state.

 

[more ...]

Details...

SwiftUI Shapes SwiftUI Shapes

by Annett Schwarze | 2025-02-14

Using SwiftUI shapes is simple. Shapes can be added to views by just creating them with Circle(), Rectangle() or one of the others.

 

[more ...]

Details...

Basic SwiftUI Charts Basic SwiftUI Charts Screenshot

by Annett Schwarze | 2025-01-31

Creating a chart is very simple. There is a Chart view and that view has some marks like LineMark views.

 

[more ...]

Details...

www.admadic.de | webmaster@admadic.de | Legal Notice and Trademarks | Privacy
© 2005-2007 - admaDIC | All Rights Reserved
All other trademarks and/or registered trademarks are the property of their respective owners
Last Change: Fri Jun 20 08:11:04 2025 GMT