-
-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Form Field types (PDF 1.7 Section 12.7.4) #23
Conversation
I once again went with a prefix based approach to make the specific functions for |
src/forms.rs
Outdated
// TODO: the spec likely means the equivalent of unicode graphemes here | ||
// for characters | ||
|
||
/// Write the `/MaxLen` attribute to set the maximum length of the fields | ||
/// text in characters. Only permissible on text fields. | ||
pub fn text_max_len(&mut self, len: i32) -> &mut Self { | ||
self.dict.pair(Name(b"MaxLen"), len); | ||
self | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As noted here, I was looking for mentions of character
in the spec and couldn't really find what they define to be a character, but I assume this is about what the user sees.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@reknih this is still relevant, unfortunately moving the code around has marked this as outdated.
While this is marked as ready for review, there is still some work to do, like exporting the types and such. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a huge section of the spec so there are bound to be some comments. You are making good progress.
This PR adds the writers and types for writing various types form fields.
Signature Fields(Left out to reduce review surface to in turn ensure correct implementation)