Skip to content
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

Improvements on Method comments. #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Commits on May 21, 2024

  1. Improvements on Method comments.

    * Added parameter and return type documentation for initialization methods.
    
    * Provided example usage for the `fancyTextViewWithFrame:markupText: method`.
    
    Before:
    
    ```objc
    /// The GSFancyText object for this view
    @Property (nonatomic, retain) GSFancyText* fancyText;
    
    /// The content height of the fancyText object.
    @Property (nonatomic, assign, readonly) CGFloat contentHeight;
    
    /** If matchFrameHeightToContent is set to YES, the view frame height will be set to match the content height
     * every time updateDisplay method is called.
     *
     * If it's set to NO, every time we call updateDisplay, only the new width will be used to affect the line height.
     */
    @Property (nonatomic, assign) BOOL matchFrameHeightToContent;
    
    
    /** If it is set to YES, the view frame width will be set to match the content width (if the actually content is narrower than assigned width)
     * every time updateDisplay method is called.
     */
    @Property (nonatomic, assign) BOOL matchFrameWidthToContent;
    ```
    
    After:
    
    ```objc
    /// The GSFancyText object for this view.
    @Property (nonatomic, retain) GSFancyText *fancyText;
    
    /// The content height of the fancyText object.
    @Property (nonatomic, assign, readonly) CGFloat contentHeight;
    
    /** Determines whether the view frame height should match the content height.
     *
     * If set to YES, the view frame height will be set to match the content height
     * every time the updateDisplay method is called.
     *
     * If set to NO, the new width will be used to affect the line height when updateDisplay is called.
     */
    @Property (nonatomic, assign) BOOL matchFrameHeightToContent;
    
    /** Determines whether the view frame width should match the content width.
     *
     * If set to YES, the view frame width will be set to match the content width (if the actual content is narrower than the assigned width)
     * every time the updateDisplay method is called.
     */
    @Property (nonatomic, assign) BOOL matchFrameWidthToContent;
    ```
    * Added spaces between the type and the asterisk in pointer declarations (e.g., `GSFancyText *fancyText_` instead of `GSFancyText* fancyText_`).
    
    * Ensured consistent use of indentation and spacing throughout the file.
    Montana authored May 21, 2024
    Configuration menu
    Copy the full SHA
    5c63063 View commit details
    Browse the repository at this point in the history