Comments (17)
It cannot be generated automatically, so manual binding required.
from pango.
Is it hard to do? From where can I start?
from pango.
It might be a bit tricky. The issue starts here because of the AttrClass. Once AttrClass is done, it should be quick.
from pango.
Does AttrClass
can be autogenerated?
from pango.
Nope, that's the problem.
from pango.
If you're not too much into a hurry, I might be able to do it in the next hours after I'm done with my current task.
from pango.
Well, if it takes less that a month - i'm fine =)
from pango.
For the published crate, it might take a month. :D
But you'll be able to use the repository directly.
from pango.
Yep. git is fine for now.
from pango.
Ok, once #82 is merged, you'll have everything you need and even more.
from pango.
Thanks, but I can't figure out how to use it. I have:
let attr = pango::functions::attr_underline_new(pango::Underline::Single);
And now I have to insert it to the attributes list, which should look like:
PangoAttrList *attr_list = pango_attr_list_new();
PangoAttribute *attribute = pango_attr_underline_new(PANGO_UNDERLINE_SINGLE);
attribute->start_index = 0;
attribute->end_index = -1;
pango_attr_list_insert(attr_list, attribute);
pango_layout_set_attributes(layout, attr_list);
pango_attr_list_unref(attr_list);
But none of these methods are implemented.
from pango.
It different from that you say on start issue ;)
When AttrList
added to generation, gir generate all needed functions (with need some const
fixes).
Only need add manual setters for attribute fields to https://github.com/gtk-rs/pango/blob/master/src/attribute.rs.
from pango.
Hm. Seems pango_attr_list_insert
and 3 others maybe need some manual implementation if don't works after const
-configure.
from pango.
It different from that you say on start issue
I agree, but why I need Attr
creating without using it =)
Only need add manual setters for attribute fields
But pango_layout_set_attributes
is still commented out.
from pango.
It will be uncommented after generating AttrList
from pango.
I see. The gir
stuff is still magic for me.
Should I create a new issue for this?
from pango.
Yes please. And this time specify everything you need. :)
from pango.
Related Issues (12)
- Remove the Option return type for all types creation HOT 2
- Does not include cairo backend rendering. HOT 7
- Relicense under dual MIT/Apache-2.0 HOT 11
- Why does Layout::set_text need a length argument? HOT 15
- Incorrect implementation of Layout::xy_to_index
- Support pango_itemize API HOT 5
- Add text style attributes support HOT 4
- Pango::Language::get_sample_string() SIGSEGVing
- Missing bindings for PangoGravity functions HOT 3
- Update pango bindings HOT 6
- need an enum for the PangoScale values HOT 6
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 pango.