Comments (9)
I am reading the code in the cocoa package currently. This package has 35 files in it. It has one big file called cocoa_objc.gen.go. This file is over 21,000 lines long and has the implementation of many objective-c classes in it. One thing I don't understand yet is why there are other files in this folder. For example the cocoa_objc.gen.go file has the implementation of several NSFont methods. But there is still a file in the package called NSFont.go. This file only has one method implemented in it. Why is the NSFont.go file needed?
from macdriver.
I did more research on the core package and found out it has the same format. The package contains one large file called core_objc.gen.go and a bunch of little files with the names of classes in objective-c. The core_objc.gen.go file seems to have code in it that translates objective-c to c, then from c to go. The other files seem to make the go code more human-friendly.
I am guessing the "gen" in core_objc.gen.go is for "generated". If this file was generated using a program could we see this program?
from macdriver.
Just wanted to note if this tutorial is made, a section should be included that tells the user how to test out changes to this project.
from macdriver.
You're right, and there is tooling here to generate that code based on schemas produced by the project macschema which is all still under development, though not actively by me at the moment. It will take some time for me to get back into it all and make sure it all works and create tutorials like this but thanks to you and others, I'm trying to find ways to prioritize it.
from macdriver.
Some of this has been started in the project wiki here, for example:
https://github.com/progrium/macdriver/wiki/HowToAddTypes
from macdriver.
I made the tutorial: https://github.com/progrium/macdriver/wiki/How-to-Contribute
Please let me know what you think. Suggestions and corrections are always welcomed.
from macdriver.
I made the tutorial: https://github.com/progrium/macdriver/wiki/How-to-Contribute Please let me know what you think. Suggestions and corrections are always welcomed.
it might be better to suggest using a go.work file vs the replace directive.
from macdriver.
@tmc the issue with that is it requires Go 1.18 or higher. There probably are people who are still using older versions of Go who might want to contribute.
from macdriver.
Closing for now. At some point I'll try to clean it up, but good first pass.
from macdriver.
Related Issues (20)
- SetDefaultApplicationAtURLToOpenContentTypeCompletionHandler error
- ComboBox `SetDelegate` uses `TextField`'s `SetDelegte` resulting in error HOT 1
- module github.com/progrium/macdriver@latest found (v0.4.0), but does not contain package github.com/progrium/macdriver/keycode HOT 2
- Can I use Network Extension HOT 2
- Framework Request: ScreenCaptureKit
- DarwinKit: Rendering Problem with OutlineView
- SetDuration Can not set duration for amination
- Nib's InstantiateWithOwnerTopLevelObjects() not returning objects HOT 9
- Generator change: keep Objective-C type when parameter is a pointer to a pointer HOT 1
- Framework Request: StoreKit HOT 2
- enumexport error with call to s.Parse
- Generating appkit problem with enumtypes.gen.go and aliastypes.gen.go
- APFS (Case-sensitive) filesystem protocols.gen.m:3:9: fatal error:: 'Appkit/Appkit.h' file not found
- Can macdriver be used to implement macOS widgets and install them directly into the macOS notification center or desktop?
- corelocation API giving panic HOT 6
- Dictionary's DictionaryWithObjectsAndKeys() throws NSInvalidArgumentException HOT 6
- An error occurs when running the layout example. HOT 2
- Notification example doesnโt work. HOT 1
- user-agent? HOT 1
- Can not create Event Taps HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from macdriver.