class Redbreast::TemplateGenerator::Image::ObjC

Used for creating images in objective-c.

Public Instance Methods

h_template() click to toggle source
# File lib/redbreast/template_generators/images/objc_images_template_generator.rb, line 9
        def h_template
          <<~TEMPLATE

            #import <UIKit/UIKit.h>

            //THIS FILE IS AUTOGENERATED, DO NOT EDIT BY HAND
            <%= generate_category('interface', 'UIImage', app_name) %>
            <%= generate_h_file_objc(names: asset_names, variable: '+ (UIColor *)%s;\n')%>
            @end
          TEMPLATE
        end
m_template() click to toggle source
# File lib/redbreast/template_generators/images/objc_images_template_generator.rb, line 21
        def m_template
          <<~TEMPLATE

            #import <UIKit/UIKit.h>

            //THIS FILE IS AUTOGENERATED, DO NOT EDIT BY HAND
            <%= generate_category('implementation', 'UIImage', app_name) %>
            <%= generate_m_file_objc(names: asset_names, variable_declaration: '+ (UIImage *)%s\n{', variable_implementation: '\n\treturn [UIColor imageNamed:@"%s" inBundle:%s compatibleWithTraitCollection:nil];\n}\n', bundle_name: bundle) %>
            @end
          TEMPLATE
        end