{"id":18382442,"url":"https://github.com/ntd/adg","last_synced_at":"2025-04-06T23:31:42.269Z","repository":{"id":5212395,"uuid":"6388251","full_name":"ntd/adg","owner":"ntd","description":"A canvas for generating technical drawings","archived":false,"fork":false,"pushed_at":"2022-05-19T19:27:32.000Z","size":4914,"stargazers_count":18,"open_issues_count":0,"forks_count":7,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-03-22T09:02:24.888Z","etag":null,"topics":["adg","cad","cairo","canvas","dxf","pdf","png","technical-drafting","technical-drawing"],"latest_commit_sha":null,"homepage":"https://adg.entidi.com/","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"eRGoon/RGPageViewController","license":"lgpl-2.1","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ntd.png","metadata":{"files":{"readme":"README.md","changelog":"ChangeLog-0.2.1","contributing":null,"funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-10-25T14:09:58.000Z","updated_at":"2025-03-03T12:18:25.000Z","dependencies_parsed_at":"2022-09-24T03:34:43.206Z","dependency_job_id":null,"html_url":"https://github.com/ntd/adg","commit_stats":null,"previous_names":[],"tags_count":38,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ntd%2Fadg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ntd%2Fadg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ntd%2Fadg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ntd%2Fadg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ntd","download_url":"https://codeload.github.com/ntd/adg/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247569123,"owners_count":20959758,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["adg","cad","cairo","canvas","dxf","pdf","png","technical-drafting","technical-drawing"],"created_at":"2024-11-06T01:05:40.499Z","updated_at":"2025-04-06T23:31:37.255Z","avatar_url":"https://github.com/ntd.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"General information\n===================\n[![Pipeline Status](https://gitlab.com/libadg/adg/badges/master/pipeline.svg)](https://gitlab.com/libadg/adg/-/pipelines)\n[![Coverage Status](https://gitlab.com/libadg/adg/badges/master/coverage.svg)](https://gitlab.com/libadg/adg/-/commits)\n\nAutomatic Drawing Generation is GObject-based library that provides\na non-interactive cairo canvas specifically designed for generating\ntechnical drawings. It can be viewed as a 2D CAD without user\ninterface.\n\nIf you want to develop an application that needs to show and print\ndrawings where some data change but the overall design is similar,\nthe ADG library can be quite useful. In manufacturing industries\nthis is often the case and an ADG-based application could help to\ngreatly improve the productivity of technical offices.\n\nYou could reach similar targets using parametric CADs but a custom\napplication provides the following benefits:\n\n * more customizable;\n * quicker and not so bloated as a parametric CAD;\n * can be easily connected to a database;\n * an ADG based filter can generate drawing on-fly: this feature\n   could be used in web-based applications.\n\nVisit the [ADG web site](https://adg.entidi.com/) for further\ndetails.\n\n\nDesign overview\n===============\n\nThe project is based on the [GObject](https://www.gtk.org/) library:\nthe ADG canvas is developed in plain C using an object-oriented\napproach. Applications based on ADG are not expected to be\ndeveloped in C, though: the basic idea is to have a set of bindings\nfor higher level languages (the garbage-collected ones, above all).\nAn application can then be developed using any specific language\navailable, much in the same way as [GNOME](https://www.gnome.org/)\napplications are conceived.\n\nLua bindings based on [LGI](https://github.com/lgi-devs/lgi) are\nalready availables and effectively used upstream to test the APIs.\nThe [adg-lua](https://github.com/ntd/adg-lua) project provides code\nexamples on how to use them. A modern web approach is shown by the\n[adg-openresty](https://github.com/ntd/adg-openresty) project, where\nthe Lua bindings are directly used inside an NGINX webserver.\n\nThe mathematical and geometrical algorithms, together with a bunch\nof other useful functions for manipulating cairo paths, are kept\nin a separated library called `CPML` (Cairo Path Manipulation Library).\nAlthough actually embedded into the ADG project, this library can be\neasily splitted on its own, if needed.\n\nThe rendering leverages [cairo](https://www.cairographics.org/), so\nthe ADG canvas fully shares strong and weak points of that library.\nMost notably, the availables export formats include PostScript, SVG,\nPDF, PNG but no CAD specific ones (such as DXF).\n\n\nExternal dependencies\n=====================\n\nThe ADG library has the following dependencies:\n\n * [cairo](https://www.cairographics.org/) 1.7.4 or later, required\n   by both CPML and ADG;\n * [GLib](https://www.gtk.org/) 2.38.0 or later, required by ADG;\n * [GTK](https://www.gtk.org/) 3.0.0 or later (or GTK 2.18.0 or\n   later for GTK2 support) to optionally include GTK support and build\n   the `adg-demo` program;\n * [pango](https://pango.gnome.org/) 1.10.0 or later (optional) to\n   support a serious engine for rendering text instead of using the\n   cairo \"toy\" APIs (only the `pango-cairo` module will be used);\n * [gtk-doc](https://wiki.gnome.org/DocumentationProject/GtkDoc) 1.12\n   or later (optional), used to regenerate the API documentation;\n * [GObject introspection](https://gi.readthedocs.io/) 1.0.0 or later\n   (optional) to dinamically generate bindings metadata.\n\nThe required packages must be installed prior the ADG building:\nthey should be availables on nearly every decent unix-like system.\n\nThe ADG is mainly developed on GNU/Linux but its dependecies are\nknown to be cross platform so a porting should be quite easy, if\nnot automatic.\n\n\nInstallation\n============\n\nThe ADG build system is based on meson but a legacy autotools based\nsystem is still supported.\n\nThe following instructions are included only for reference: you are\nexpected to customize and install the ADG in the way you prefer.\nJust remember (if you are copying and pasting) to put the proper\npackage version instead of `0.9.4` and to select the appropriate\ncommands for meson or autotools based builds.\n\n1. Unpack the ADG tarball somewhere in your file system: your home\n   folder is a good candidate. You can get the latest tarball from\n   [GitHub](https://github.com/ntd/adg/releases).\n    ```\n    # For meson-based builds\n    wget https://github.com/ntd/adg/releases/download/0.9.4/adg-0.9.4.tar.xz\n    tar xf adg-0.9.4.tar.xz\n    cd adg-0.9.4\n    # For autotools-based builds\n    wget https://github.com/ntd/adg/releases/download/0.9.4/adg-0.9.4.tar.bz2\n    tar xf adg-0.9.4.tar.bz2\n    cd adg-0.9.4\n    ```\n2. Configure and run the build using meson or autotools (the former\n   only available on adg \u003e= 0.9.4). The autotools build system will\n   be dropped somewhere in the future.\n    ```\n    # Using meson\n    meson build\n    cd build\n    ninja\n    # Using autotools (VPATH build)\n    mkdir build \u0026\u0026 cd build\n    ../configure\n    make\n    ```\n3. Once the building has finished, you are able to run the demo\n   program without installing anything. Just try it out by\n   launching the uninstalled executable:\n    ```\n    demo/adg-demo\n    ```\n4. Permanently install the ADG. You must usually have root privileges\n   if you intend to install it in your system folders.\n    ```\n    # Using meson\n    ninja intall\n    # Using autotools\n    make install\n    ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fntd%2Fadg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fntd%2Fadg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fntd%2Fadg/lists"}