Merge pull request #4 from Lo-X/master

Font Awesome 4.0.3, enum classes
This commit is contained in:
Rick Blommers 2014-05-07 19:56:40 +02:00
commit 2841b6ba8d
8 changed files with 762 additions and 827 deletions

View File

@ -167,7 +167,7 @@ bool QtAwesome::initFontAwesome( )
Q_INIT_RESOURCE(QtAwesome);
// load the font file
QFile res(":/fonts/fontawesome.ttf");
QFile res(":/fonts/fontawesome-4.0.3.ttf");
if(!res.open(QIODevice::ReadOnly)) {
qDebug() << "Font awesome font could not be loaded!";
return false;
@ -189,415 +189,381 @@ bool QtAwesome::initFontAwesome( )
}
// intialize the map
QHash<QString, int>& m = namedCodepoints_;
m.insert( "glass", icon_glass );
m.insert( "music", icon_music );
m.insert( "search", icon_search );
m.insert( "envelope", icon_envelope );
m.insert( "heart", icon_heart );
m.insert( "star", icon_star );
m.insert( "star-empty", icon_star_empty );
m.insert( "user", icon_user );
m.insert( "film", icon_film );
m.insert( "th-large", icon_th_large );
m.insert( "th", icon_th );
m.insert( "th-list", icon_th_list );
m.insert( "ok", icon_ok );
m.insert( "remove", icon_remove );
m.insert( "zoom-in", icon_zoom_in );
m.insert( "zoom-out", icon_zoom_out );
m.insert( "off", icon_off );
m.insert( "signal", icon_signal );
m.insert( "cog", icon_cog );
m.insert( "gear", icon_gear );
m.insert( "trash", icon_trash );
m.insert( "home", icon_home );
m.insert( "file_alt", icon_file_alt );
m.insert( "time", icon_time );
m.insert( "road", icon_road );
m.insert( "download-alt", icon_download_alt );
m.insert( "download", icon_download );
m.insert( "upload", icon_upload );
m.insert( "inbox", icon_inbox );
m.insert( "play-circle", icon_play_circle );
m.insert( "repeat", icon_repeat );
/* \f020 doesn't work in Safari. all shifted one down */
m.insert( "refresh", icon_refresh );
m.insert( "list-alt", icon_list_alt );
m.insert( "lock", icon_lock );
m.insert( "flag", icon_flag );
m.insert( "headphones", icon_headphones );
m.insert( "volume-off", icon_volume_off );
m.insert( "volume-down", icon_volume_down );
m.insert( "volume-up", icon_volume_up );
m.insert( "qrcode", icon_qrcode );
m.insert( "barcode", icon_barcode );
m.insert( "tag", icon_tag );
m.insert( "tags", icon_tags );
m.insert( "book", icon_book );
m.insert( "bookmark", icon_bookmark );
m.insert( "print", icon_print );
m.insert( "camera", icon_camera );
m.insert( "font", icon_font );
m.insert( "bold", icon_bold );
m.insert( "italic", icon_italic );
m.insert( "text-height", icon_text_height );
m.insert( "text-width", icon_text_width );
m.insert( "align-left", icon_align_left );
m.insert( "align-center", icon_align_center );
m.insert( "align-right", icon_align_right );
m.insert( "align-justify", icon_align_justify );
m.insert( "list", icon_list );
m.insert( "indent-left", icon_indent_left );
m.insert( "indent-right", icon_indent_right );
m.insert( "facetime-video", icon_facetime_video );
m.insert( "picture", icon_picture );
m.insert( "pencil", icon_pencil );
m.insert( "map-marker", icon_map_marker );
m.insert( "adjust", icon_adjust );
m.insert( "tint", icon_tint );
m.insert( "edit", icon_edit );
m.insert( "share", icon_share );
m.insert( "check", icon_check );
m.insert( "move", icon_move );
m.insert( "step-backward", icon_step_backward );
m.insert( "fast-backward", icon_fast_backward );
m.insert( "backward", icon_backward );
m.insert( "play", icon_play );
m.insert( "pause", icon_pause );
m.insert( "stop", icon_stop );
m.insert( "forward", icon_forward );
m.insert( "fast-forward", icon_fast_forward );
m.insert( "step-forward", icon_step_forward );
m.insert( "eject", icon_eject );
m.insert( "chevron-left", icon_chevron_left );
m.insert( "chevron-right", icon_chevron_right );
m.insert( "plus-sign", icon_plus_sign );
m.insert( "minus-sign", icon_minus_sign );
m.insert( "remove-sign", icon_remove_sign );
m.insert( "ok-sign", icon_ok_sign );
m.insert( "question-sign", icon_question_sign );
m.insert( "info-sign", icon_info_sign );
m.insert( "screenshot", icon_screenshot );
m.insert( "remove-circle", icon_remove_circle );
m.insert( "ok-circle", icon_ok_circle );
m.insert( "ban-circle", icon_ban_circle );
m.insert( "arrow-left", icon_arrow_left );
m.insert( "arrow-right", icon_arrow_right );
m.insert( "arrow-up", icon_arrow_up );
m.insert( "arrow-down", icon_arrow_down );
m.insert( "share-alt", icon_share_alt );
m.insert( "resize-full", icon_resize_full );
m.insert( "resize-small", icon_resize_small );
m.insert( "plus", icon_plus );
m.insert( "minus", icon_minus );
m.insert( "asterisk", icon_asterisk );
m.insert( "exclamation-sign", icon_exclamation_sign );
m.insert( "gift", icon_gift );
m.insert( "leaf", icon_leaf );
m.insert( "fire", icon_fire );
m.insert( "eye-open", icon_eye_open );
m.insert( "eye-close", icon_eye_close );
m.insert( "warning-sign", icon_warning_sign );
m.insert( "plane", icon_plane );
m.insert( "calendar", icon_calendar );
m.insert( "random", icon_random );
m.insert( "comment", icon_comment );
m.insert( "magnet", icon_magnet );
m.insert( "chevron-up", icon_chevron_up );
m.insert( "chevron-down", icon_chevron_down );
m.insert( "retweet", icon_retweet );
m.insert( "shopping-cart", icon_shopping_cart );
m.insert( "folder-close", icon_folder_close );
m.insert( "folder-open", icon_folder_open );
m.insert( "resize-vertical", icon_resize_vertical );
m.insert( "resize-horizontal", icon_resize_horizontal );
m.insert( "bar-chart", icon_bar_chart );
m.insert( "twitter-sign", icon_twitter_sign );
m.insert( "facebook-sign", icon_facebook_sign );
m.insert( "camera-retro", icon_camera_retro );
m.insert( "key", icon_key );
m.insert( "cogs", icon_cogs );
m.insert( "gears", icon_gears );
m.insert( "comments", icon_comments );
m.insert( "thumbs-up-alt", icon_thumbs_up_alt );
m.insert( "thumbs-down-alt", icon_thumbs_down_alt );
m.insert( "star-half", icon_star_half );
m.insert( "heart-empty", icon_heart_empty );
m.insert( "signout", icon_signout );
m.insert( "linkedin-sign", icon_linkedin_sign );
m.insert( "pushpin", icon_pushpin );
m.insert( "external-link", icon_external_link );
m.insert( "signin", icon_signin );
m.insert( "trophy", icon_trophy );
m.insert( "github-sign", icon_github_sign );
m.insert( "upload-alt", icon_upload_alt );
m.insert( "lemon", icon_lemon );
m.insert( "phone", icon_phone );
m.insert( "check-empty", icon_check_empty );
m.insert( "bookmark-empty", icon_bookmark_empty );
m.insert( "phone-sign", icon_phone_sign );
m.insert( "twitter", icon_twitter );
m.insert( "facebook", icon_facebook );
m.insert( "github", icon_github );
m.insert( "unlock", icon_unlock );
m.insert( "credit-card", icon_credit_card );
m.insert( "rss", icon_rss );
m.insert( "hdd", icon_hdd );
m.insert( "bullhorn", icon_bullhorn );
m.insert( "bell", icon_bell );
m.insert( "certificate", icon_certificate );
m.insert( "hand-right", icon_hand_right );
m.insert( "hand-left", icon_hand_left );
m.insert( "hand-up", icon_hand_up );
m.insert( "hand-down", icon_hand_down );
m.insert( "circle-arrow-left", icon_circle_arrow_left );
m.insert( "circle-arrow-right", icon_circle_arrow_right );
m.insert( "circle-arrow-up", icon_circle_arrow_up );
m.insert( "circle-arrow-down", icon_circle_arrow_down );
m.insert( "globe", icon_globe );
m.insert( "wrench", icon_wrench );
m.insert( "tasks", icon_tasks );
m.insert( "filter", icon_filter );
m.insert( "briefcase", icon_briefcase );
m.insert( "fullscreen", icon_fullscreen );
m.insert( "group", icon_group );
m.insert( "link", icon_link );
m.insert( "cloud", icon_cloud );
m.insert( "beaker", icon_beaker );
m.insert( "cut", icon_cut );
m.insert( "copy", icon_copy );
m.insert( "paper-clip", icon_paper_clip );
m.insert( "save", icon_save );
m.insert( "sign-blank", icon_sign_blank );
m.insert( "reorder", icon_reorder );
m.insert( "list-ul", icon_list_ul );
m.insert( "list-ol", icon_list_ol );
m.insert( "strikethrough", icon_strikethrough );
m.insert( "underline", icon_underline );
m.insert( "table", icon_table );
m.insert( "magic", icon_magic );
m.insert( "truck", icon_truck );
m.insert( "pinterest", icon_pinterest );
m.insert( "pinterest-sign", icon_pinterest_sign );
m.insert( "google-plus-sign", icon_google_plus_sign );
m.insert( "google-plus", icon_google_plus );
m.insert( "money", icon_money );
m.insert( "caret-down", icon_caret_down );
m.insert( "caret-up", icon_caret_up );
m.insert( "caret-left", icon_caret_left );
m.insert( "caret-right", icon_caret_right );
m.insert( "columns", icon_columns );
m.insert( "sort", icon_sort );
m.insert( "sort-down", icon_sort_down );
m.insert( "sort-up", icon_sort_up );
m.insert( "envelope-alt", icon_envelope_alt );
m.insert( "linkedin", icon_linkedin );
m.insert( "undo", icon_undo );
m.insert( "legal", icon_legal );
m.insert( "dashboard", icon_dashboard );
m.insert( "comment-alt", icon_comment_alt );
m.insert( "comments-alt", icon_comments_alt );
m.insert( "bolt", icon_bolt );
m.insert( "sitemap", icon_sitemap );
m.insert( "umbrella", icon_umbrella );
m.insert( "paste", icon_paste );
m.insert( "lightbulb", icon_lightbulb );
m.insert( "exchange", icon_exchange );
m.insert( "cloud-download", icon_cloud_download );
m.insert( "cloud-upload", icon_cloud_upload );
m.insert( "user-md", icon_user_md );
m.insert( "stethoscope", icon_stethoscope );
m.insert( "suitcase", icon_suitcase );
m.insert( "bell-alt", icon_bell_alt );
m.insert( "coffee", icon_coffee );
m.insert( "food", icon_food );
m.insert( "file-text-alt", icon_file_text_alt );
m.insert( "building", icon_building );
m.insert( "hospital", icon_hospital );
m.insert( "ambulance", icon_ambulance );
m.insert( "medkit", icon_medkit );
m.insert( "fighter-jet", icon_fighter_jet );
m.insert( "beer", icon_beer );
m.insert( "h-sign", icon_h_sign );
m.insert( "plus-sign-alt", icon_plus_sign_alt );
m.insert( "double-angle-left", icon_double_angle_left );
m.insert( "double-angle-right", icon_double_angle_right );
m.insert( "double-angle-up", icon_double_angle_up );
m.insert( "double-angle-down", icon_double_angle_down );
m.insert( "angle-left", icon_angle_left );
m.insert( "angle-right", icon_angle_right );
m.insert( "angle-up", icon_angle_up );
m.insert( "angle-down", icon_angle_down );
m.insert( "desktop", icon_desktop );
m.insert( "laptop", icon_laptop );
m.insert( "tablet", icon_tablet );
m.insert( "mobile-phone", icon_mobile_phone );
m.insert( "circle-blank", icon_circle_blank );
m.insert( "quote-left", icon_quote_left );
m.insert( "quote-right", icon_quote_right );
m.insert( "spinner", icon_spinner );
m.insert( "circle", icon_circle );
m.insert( "reply", icon_reply );
m.insert( "mail_reply", icon_mail_reply );
m.insert( "github-alt", icon_github_alt );
m.insert( "folder-close-alt", icon_folder_close_alt );
m.insert( "folder-open-alt", icon_folder_open_alt );
m.insert( "expand_alt", icon_expand_alt );
m.insert( "collapse_alt", icon_collapse_alt );
m.insert( "smile", icon_smile );
m.insert( "frown", icon_frown );
m.insert( "meh", icon_meh );
m.insert( "gamepad", icon_gamepad );
m.insert( "keyboard", icon_keyboard );
m.insert( "flag_alt", icon_flag_alt );
m.insert( "flag_checkered", icon_flag_checkered );
m.insert( "terminal", icon_terminal );
m.insert( "code", icon_code );
m.insert( "reply_all", icon_reply_all );
m.insert( "mail_reply_all", icon_mail_reply_all );
m.insert( "star_half_full", icon_star_half_full );
m.insert( "star_half_empty", icon_star_half_empty );
m.insert( "location_arrow", icon_location_arrow );
m.insert( "crop", icon_crop );
m.insert( "code_fork", icon_code_fork );
m.insert( "unlink", icon_unlink );
m.insert( "question", icon_question );
m.insert( "info", icon_info );
m.insert( "exclamation", icon_exclamation );
m.insert( "superscript", icon_superscript );
m.insert( "subscript", icon_subscript );
m.insert( "eraser", icon_eraser );
m.insert( "puzzle_piece", icon_puzzle_piece );
m.insert( "microphone", icon_microphone );
m.insert( "microphone_off", icon_microphone_off );
m.insert( "shield", icon_shield );
m.insert( "calendar_empty", icon_calendar_empty );
m.insert( "fire_extinguisher", icon_fire_extinguisher );
m.insert( "rocket", icon_rocket );
m.insert( "maxcdn", icon_maxcdn );
m.insert( "chevron_sign_left", icon_chevron_sign_left );
m.insert( "chevron_sign_right", icon_chevron_sign_right );
m.insert( "chevron_sign_up", icon_chevron_sign_up );
m.insert( "chevron_sign_down", icon_chevron_sign_down );
m.insert( "html5", icon_html5 );
m.insert( "css3", icon_css3 );
m.insert( "anchor", icon_anchor );
m.insert( "unlock_alt", icon_unlock_alt );
m.insert( "bullseye", icon_bullseye );
m.insert( "ellipsis_horizontal", icon_ellipsis_horizontal );
m.insert( "ellipsis_vertical", icon_ellipsis_vertical );
m.insert( "rss_sign", icon_rss_sign );
m.insert( "play_sign", icon_play_sign );
m.insert( "ticket", icon_ticket );
m.insert( "minus_sign_alt", icon_minus_sign_alt );
m.insert( "check_minus", icon_check_minus );
m.insert( "level_up", icon_level_up );
m.insert( "level_down", icon_level_down );
m.insert( "check_sign", icon_check_sign );
m.insert( "edit_sign", icon_edit_sign );
m.insert( "external_link_sign", icon_external_link_sign );
m.insert( "share_sign", icon_share_sign );
// v3.2.0
m.insert( "compass", icon_compass );
m.insert( "collapse", icon_collapse );
m.insert( "collapse_top", icon_collapse_top );
m.insert( "expand", icon_expand );
m.insert( "euro", icon_euro );
m.insert( "eur", icon_eur );
m.insert( "gbp", icon_gbp );
m.insert( "dollar", icon_dollar );
m.insert( "usd", icon_usd );
m.insert( "rupee", icon_rupee );
m.insert( "inr", icon_inr );
m.insert( "yen", icon_yen );
m.insert( "jpy", icon_jpy );
m.insert( "renminbi", icon_renminbi );
m.insert( "cny", icon_cny );
m.insert( "won", icon_won );
m.insert( "krw", icon_krw );
m.insert( "bitcoin", icon_bitcoin );
m.insert( "btc", icon_btc );
m.insert( "file", icon_file );
m.insert( "file_text", icon_file_text );
m.insert( "sort_by_alphabet", icon_sort_by_alphabet );
m.insert( "sort_by_alphabet_alt", icon_sort_by_alphabet_alt );
m.insert( "sort_by_attributes", icon_sort_by_attributes );
m.insert( "sort_by_attributes_alt", icon_sort_by_attributes_alt );
m.insert( "sort_by_order", icon_sort_by_order );
m.insert( "sort_by_order_alt", icon_sort_by_order_alt );
m.insert( "thumbs_up", icon_thumbs_up );
m.insert( "thumbs_down", icon_thumbs_down );
m.insert( "youtube_sign", icon_youtube_sign );
m.insert( "youtube", icon_youtube );
m.insert( "xing", icon_xing );
m.insert( "xing_sign", icon_xing_sign );
m.insert( "youtube_play", icon_youtube_play );
m.insert( "dropbox", icon_dropbox );
m.insert( "stackexchange", icon_stackexchange );
m.insert( "instagram", icon_instagram );
m.insert( "flickr", icon_flickr );
m.insert( "adn", icon_adn );
m.insert( "bitbucket", icon_bitbucket );
m.insert( "bitbucket_sign", icon_bitbucket_sign );
m.insert( "tumblr", icon_tumblr );
m.insert( "tumblr_sign", icon_tumblr_sign );
m.insert( "long_arrow_down", icon_long_arrow_down );
m.insert( "long_arrow_up", icon_long_arrow_up );
m.insert( "long_arrow_left", icon_long_arrow_left );
m.insert( "long_arrow_right", icon_long_arrow_right );
m.insert( "apple", icon_apple );
m.insert( "windows", icon_windows );
m.insert( "android", icon_android );
m.insert( "linux", icon_linux );
m.insert( "dribble", icon_dribble );
m.insert( "skype", icon_skype );
m.insert( "foursquare", icon_foursquare );
m.insert( "trello", icon_trello );
m.insert( "female", icon_female );
m.insert( "male", icon_male );
m.insert( "gittip", icon_gittip );
m.insert( "sun", icon_sun );
m.insert( "moon", icon_moon );
m.insert( "archive", icon_archive );
m.insert( "bug", icon_bug );
m.insert( "vk", icon_vk );
m.insert( "weibo", icon_weibo );
m.insert( "renren", icon_renren );
QHash<QString, fa>& m = namedCodepoints_;
m.insert("glass", fa::glass);
m.insert("music", fa::music);
m.insert("search", fa::search);
m.insert("envelopeo", fa::envelopeo);
m.insert("heart", fa::heart);
m.insert("star", fa::star);
m.insert("staro", fa::staro);
m.insert("user", fa::user);
m.insert("film", fa::film);
m.insert("thlarge", fa::thlarge);
m.insert("th", fa::th);
m.insert("thlist", fa::thlist);
m.insert("check", fa::check);
m.insert("times", fa::times);
m.insert("searchplus", fa::searchplus);
m.insert("searchminus", fa::searchminus);
m.insert("poweroff", fa::poweroff);
m.insert("signal", fa::signal);
m.insert("cog", fa::cog);
m.insert("trasho", fa::trasho);
m.insert("home", fa::home);
m.insert("fileo", fa::fileo);
m.insert("clocko", fa::clocko);
m.insert("road", fa::road);
m.insert("download", fa::download);
m.insert("arrowcircleodown", fa::arrowcircleodown);
m.insert("arrowcircleoup", fa::arrowcircleoup);
m.insert("inbox", fa::inbox);
m.insert("playcircleo", fa::playcircleo);
m.insert("repeat", fa::repeat);
m.insert("refresh", fa::refresh);
m.insert("listalt", fa::listalt);
m.insert("lock", fa::lock);
m.insert("flag", fa::flag);
m.insert("headphones", fa::headphones);
m.insert("volumeoff", fa::volumeoff);
m.insert("volumedown", fa::volumedown);
m.insert("volumeup", fa::volumeup);
m.insert("qrcode", fa::qrcode);
m.insert("barcode", fa::barcode);
m.insert("tag", fa::tag);
m.insert("tags", fa::tags);
m.insert("book", fa::book);
m.insert("bookmark", fa::bookmark);
m.insert("print", fa::print);
m.insert("camera", fa::camera);
m.insert("font", fa::font);
m.insert("bold", fa::bold);
m.insert("italic", fa::italic);
m.insert("textheight", fa::textheight);
m.insert("textwidth", fa::textwidth);
m.insert("alignleft", fa::alignleft);
m.insert("aligncenter", fa::aligncenter);
m.insert("alignright", fa::alignright);
m.insert("alignjustify", fa::alignjustify);
m.insert("list", fa::list);
m.insert("outdent", fa::outdent);
m.insert("indent", fa::indent);
m.insert("videocamera", fa::videocamera);
m.insert("pictureo", fa::pictureo);
m.insert("pencil", fa::pencil);
m.insert("mapmarker", fa::mapmarker);
m.insert("adjust", fa::adjust);
m.insert("tint", fa::tint);
m.insert("pencilsquareo", fa::pencilsquareo);
m.insert("sharesquareo", fa::sharesquareo);
m.insert("checksquareo", fa::checksquareo);
m.insert("arrows", fa::arrows);
m.insert("stepbackward", fa::stepbackward);
m.insert("fastbackward", fa::fastbackward);
m.insert("backward", fa::backward);
m.insert("play", fa::play);
m.insert("pause", fa::pause);
m.insert("stop", fa::stop);
m.insert("forward", fa::forward);
m.insert("fastforward", fa::fastforward);
m.insert("stepforward", fa::stepforward);
m.insert("eject", fa::eject);
m.insert("chevronleft", fa::chevronleft);
m.insert("chevronright", fa::chevronright);
m.insert("pluscircle", fa::pluscircle);
m.insert("minuscircle", fa::minuscircle);
m.insert("timescircle", fa::timescircle);
m.insert("checkcircle", fa::checkcircle);
m.insert("questioncircle", fa::questioncircle);
m.insert("infocircle", fa::infocircle);
m.insert("crosshairs", fa::crosshairs);
m.insert("timescircleo", fa::timescircleo);
m.insert("checkcircleo", fa::checkcircleo);
m.insert("ban", fa::ban);
m.insert("arrowleft", fa::arrowleft);
m.insert("arrowright", fa::arrowright);
m.insert("arrowup", fa::arrowup);
m.insert("arrowdown", fa::arrowdown);
m.insert("share", fa::share);
m.insert("expand", fa::expand);
m.insert("compress", fa::compress);
m.insert("plus", fa::plus);
m.insert("minus", fa::minus);
m.insert("asterisk", fa::asterisk);
m.insert("exclamationcircle", fa::exclamationcircle);
m.insert("gift", fa::gift);
m.insert("leaf", fa::leaf);
m.insert("fire", fa::fire);
m.insert("eye", fa::eye);
m.insert("eyeslash", fa::eyeslash);
m.insert("exclamationtriangle", fa::exclamationtriangle);
m.insert("plane", fa::plane);
m.insert("calendar", fa::calendar);
m.insert("random", fa::random);
m.insert("comment", fa::comment);
m.insert("magnet", fa::magnet);
m.insert("chevronup", fa::chevronup);
m.insert("chevrondown", fa::chevrondown);
m.insert("retweet", fa::retweet);
m.insert("shoppingcart", fa::shoppingcart);
m.insert("folder", fa::folder);
m.insert("folderopen", fa::folderopen);
m.insert("arrowsv", fa::arrowsv);
m.insert("arrowsh", fa::arrowsh);
m.insert("barcharto", fa::barcharto);
m.insert("twittersquare", fa::twittersquare);
m.insert("facebooksquare", fa::facebooksquare);
m.insert("cameraretro", fa::cameraretro);
m.insert("key", fa::key);
m.insert("cogs", fa::cogs);
m.insert("comments", fa::comments);
m.insert("thumbsoup", fa::thumbsoup);
m.insert("thumbsodown", fa::thumbsodown);
m.insert("starhalf", fa::starhalf);
m.insert("hearto", fa::hearto);
m.insert("signout", fa::signout);
m.insert("linkedinsquare", fa::linkedinsquare);
m.insert("thumbtack", fa::thumbtack);
m.insert("externallink", fa::externallink);
m.insert("signin", fa::signin);
m.insert("trophy", fa::trophy);
m.insert("githubsquare", fa::githubsquare);
m.insert("upload", fa::upload);
m.insert("lemono", fa::lemono);
m.insert("phone", fa::phone);
m.insert("squareo", fa::squareo);
m.insert("bookmarko", fa::bookmarko);
m.insert("phonesquare", fa::phonesquare);
m.insert("twitter", fa::twitter);
m.insert("facebook", fa::facebook);
m.insert("github", fa::github);
m.insert("unlock", fa::unlock);
m.insert("creditcard", fa::creditcard);
m.insert("rss", fa::rss);
m.insert("hddo", fa::hddo);
m.insert("bullhorn", fa::bullhorn);
m.insert("bell", fa::bell);
m.insert("certificate", fa::certificate);
m.insert("handoright", fa::handoright);
m.insert("handoleft", fa::handoleft);
m.insert("handoup", fa::handoup);
m.insert("handodown", fa::handodown);
m.insert("arrowcircleleft", fa::arrowcircleleft);
m.insert("arrowcircleright", fa::arrowcircleright);
m.insert("arrowcircleup", fa::arrowcircleup);
m.insert("arrowcircledown", fa::arrowcircledown);
m.insert("globe", fa::globe);
m.insert("wrench", fa::wrench);
m.insert("tasks", fa::tasks);
m.insert("filter", fa::filter);
m.insert("briefcase", fa::briefcase);
m.insert("arrowsalt", fa::arrowsalt);
m.insert("users", fa::users);
m.insert("link", fa::link);
m.insert("cloud", fa::cloud);
m.insert("flask", fa::flask);
m.insert("scissors", fa::scissors);
m.insert("fileso", fa::fileso);
m.insert("paperclip", fa::paperclip);
m.insert("floppyo", fa::floppyo);
m.insert("square", fa::square);
m.insert("bars", fa::bars);
m.insert("listul", fa::listul);
m.insert("listol", fa::listol);
m.insert("strikethrough", fa::strikethrough);
m.insert("underline", fa::underline);
m.insert("table", fa::table);
m.insert("magic", fa::magic);
m.insert("truck", fa::truck);
m.insert("pinterest", fa::pinterest);
m.insert("pinterestsquare", fa::pinterestsquare);
m.insert("googleplussquare", fa::googleplussquare);
m.insert("googleplus", fa::googleplus);
m.insert("money", fa::money);
m.insert("caretdown", fa::caretdown);
m.insert("caretup", fa::caretup);
m.insert("caretleft", fa::caretleft);
m.insert("caretright", fa::caretright);
m.insert("columns", fa::columns);
m.insert("sort", fa::sort);
m.insert("sortasc", fa::sortasc);
m.insert("sortdesc", fa::sortdesc);
m.insert("envelope", fa::envelope);
m.insert("linkedin", fa::linkedin);
m.insert("undo", fa::undo);
m.insert("gavel", fa::gavel);
m.insert("tachometer", fa::tachometer);
m.insert("commento", fa::commento);
m.insert("commentso", fa::commentso);
m.insert("bolt", fa::bolt);
m.insert("sitemap", fa::sitemap);
m.insert("umbrella", fa::umbrella);
m.insert("clipboard", fa::clipboard);
m.insert("lightbulbo", fa::lightbulbo);
m.insert("exchange", fa::exchange);
m.insert("clouddownload", fa::clouddownload);
m.insert("cloudupload", fa::cloudupload);
m.insert("usermd", fa::usermd);
m.insert("stethoscope", fa::stethoscope);
m.insert("suitcase", fa::suitcase);
m.insert("bello", fa::bello);
m.insert("coffee", fa::coffee);
m.insert("cutlery", fa::cutlery);
m.insert("filetexto", fa::filetexto);
m.insert("buildingo", fa::buildingo);
m.insert("hospitalo", fa::hospitalo);
m.insert("ambulance", fa::ambulance);
m.insert("medkit", fa::medkit);
m.insert("fighterjet", fa::fighterjet);
m.insert("beer", fa::beer);
m.insert("hsquare", fa::hsquare);
m.insert("plussquare", fa::plussquare);
m.insert("angledoubleleft", fa::angledoubleleft);
m.insert("angledoubleright", fa::angledoubleright);
m.insert("angledoubleup", fa::angledoubleup);
m.insert("angledoubledown", fa::angledoubledown);
m.insert("angleleft", fa::angleleft);
m.insert("angleright", fa::angleright);
m.insert("angleup", fa::angleup);
m.insert("angledown", fa::angledown);
m.insert("desktop", fa::desktop);
m.insert("laptop", fa::laptop);
m.insert("tablet", fa::tablet);
m.insert("mobile", fa::mobile);
m.insert("circleo", fa::circleo);
m.insert("quoteleft", fa::quoteleft);
m.insert("quoteright", fa::quoteright);
m.insert("spinner", fa::spinner);
m.insert("circle", fa::circle);
m.insert("reply", fa::reply);
m.insert("githubalt", fa::githubalt);
m.insert("foldero", fa::foldero);
m.insert("folderopeno", fa::folderopeno);
m.insert("smileo", fa::smileo);
m.insert("frowno", fa::frowno);
m.insert("meho", fa::meho);
m.insert("gamepad", fa::gamepad);
m.insert("keyboardo", fa::keyboardo);
m.insert("flago", fa::flago);
m.insert("flagcheckered", fa::flagcheckered);
m.insert("terminal", fa::terminal);
m.insert("code", fa::code);
m.insert("replyall", fa::replyall);
m.insert("mailreplyall", fa::mailreplyall);
m.insert("starhalfo", fa::starhalfo);
m.insert("locationarrow", fa::locationarrow);
m.insert("crop", fa::crop);
m.insert("codefork", fa::codefork);
m.insert("chainbroken", fa::chainbroken);
m.insert("question", fa::question);
m.insert("info", fa::info);
m.insert("exclamation", fa::exclamation);
m.insert("superscript", fa::superscript);
m.insert("subscript", fa::subscript);
m.insert("eraser", fa::eraser);
m.insert("puzzlepiece", fa::puzzlepiece);
m.insert("microphone", fa::microphone);
m.insert("microphoneslash", fa::microphoneslash);
m.insert("shield", fa::shield);
m.insert("calendaro", fa::calendaro);
m.insert("fireextinguisher", fa::fireextinguisher);
m.insert("rocket", fa::rocket);
m.insert("maxcdn", fa::maxcdn);
m.insert("chevroncircleleft", fa::chevroncircleleft);
m.insert("chevroncircleright", fa::chevroncircleright);
m.insert("chevroncircleup", fa::chevroncircleup);
m.insert("chevroncircledown", fa::chevroncircledown);
m.insert("html5", fa::html5);
m.insert("css3", fa::css3);
m.insert("anchor", fa::anchor);
m.insert("unlockalt", fa::unlockalt);
m.insert("bullseye", fa::bullseye);
m.insert("ellipsish", fa::ellipsish);
m.insert("ellipsisv", fa::ellipsisv);
m.insert("rsssquare", fa::rsssquare);
m.insert("playcircle", fa::playcircle);
m.insert("ticket", fa::ticket);
m.insert("minussquare", fa::minussquare);
m.insert("minussquareo", fa::minussquareo);
m.insert("levelup", fa::levelup);
m.insert("leveldown", fa::leveldown);
m.insert("checksquare", fa::checksquare);
m.insert("pencilsquare", fa::pencilsquare);
m.insert("externallinksquare", fa::externallinksquare);
m.insert("sharesquare", fa::sharesquare);
m.insert("compass", fa::compass);
m.insert("caretsquareodown", fa::caretsquareodown);
m.insert("caretsquareoup", fa::caretsquareoup);
m.insert("caretsquareoright", fa::caretsquareoright);
m.insert("eur", fa::eur);
m.insert("gbp", fa::gbp);
m.insert("usd", fa::usd);
m.insert("inr", fa::inr);
m.insert("jpy", fa::jpy);
m.insert("rub", fa::rub);
m.insert("krw", fa::krw);
m.insert("btc", fa::btc);
m.insert("file", fa::file);
m.insert("filetext", fa::filetext);
m.insert("sortalphaasc", fa::sortalphaasc);
m.insert("sortalphadesc", fa::sortalphadesc);
m.insert("sortamountasc", fa::sortamountasc);
m.insert("sortamountdesc", fa::sortamountdesc);
m.insert("sortnumericasc", fa::sortnumericasc);
m.insert("sortnumericdesc", fa::sortnumericdesc);
m.insert("thumbsup", fa::thumbsup);
m.insert("thumbsdown", fa::thumbsdown);
m.insert("youtubesquare", fa::youtubesquare);
m.insert("youtube", fa::youtube);
m.insert("xing", fa::xing);
m.insert("xingsquare", fa::xingsquare);
m.insert("youtubeplay", fa::youtubeplay);
m.insert("dropbox", fa::dropbox);
m.insert("stackoverflow", fa::stackoverflow);
m.insert("instagram", fa::instagram);
m.insert("flickr", fa::flickr);
m.insert("adn", fa::adn);
m.insert("bitbucket", fa::bitbucket);
m.insert("bitbucketsquare", fa::bitbucketsquare);
m.insert("tumblr", fa::tumblr);
m.insert("tumblrsquare", fa::tumblrsquare);
m.insert("longarrowdown", fa::longarrowdown);
m.insert("longarrowup", fa::longarrowup);
m.insert("longarrowleft", fa::longarrowleft);
m.insert("longarrowright", fa::longarrowright);
m.insert("appleicon", fa::appleicon);
m.insert("windowsicon", fa::windowsicon);
m.insert("androidicon", fa::androidicon);
m.insert("linuxicon", fa::linuxicon);
m.insert("dribbble", fa::dribbble);
m.insert("skype", fa::skype);
m.insert("foursquare", fa::foursquare);
m.insert("trello", fa::trello);
m.insert("female", fa::female);
m.insert("male", fa::male);
m.insert("gittip", fa::gittip);
m.insert("suno", fa::suno);
m.insert("moono", fa::moono);
m.insert("archive", fa::archive);
m.insert("bug", fa::bug);
m.insert("vk", fa::vk);
m.insert("weibo", fa::weibo);
m.insert("renren", fa::renren);
m.insert("pagelines", fa::pagelines);
m.insert("stackexchange", fa::stackexchange);
m.insert("arrowcircleoright", fa::arrowcircleoright);
m.insert("arrowcircleoleft", fa::arrowcircleoleft);
m.insert("caretsquareoleft", fa::caretsquareoleft);
m.insert("dotcircleo", fa::dotcircleo);
m.insert("wheelchair", fa::wheelchair);
m.insert("vimeosquare", fa::vimeosquare);
m.insert("tryicon", fa::tryicon);
m.insert("plussquareo", fa::plussquareo);
return true;
}
void QtAwesome::addNamedCodepoint( const QString& name, int codePoint)
void QtAwesome::addNamedCodepoint( const QString& name, fa codePoint)
{
namedCodepoints_.insert( name, codePoint);
}
@ -636,11 +602,11 @@ static QVariantMap mergeOptions( const QVariantMap& defaults, const QVariantMap&
/// <code>
/// awesome->icon( icon_group )
/// </code>
QIcon QtAwesome::icon(int character, const QVariantMap &options)
QIcon QtAwesome::icon(fa character, const QVariantMap &options)
{
// create a merged QVariantMap to have default options and icon-specific options
QVariantMap optionMap = mergeOptions( defaultOptions_, options );
optionMap.insert("text", QString( QChar(character) ) );
optionMap.insert("text", QString( QChar(static_cast<int>(character)) ) );
return icon( fontIconPainter_, optionMap );
}

View File

@ -16,409 +16,377 @@
/// A list of all icon-names with the codepoint (unicode-value) on the right
/// You can use the names on the page http://fortawesome.github.io/Font-Awesome/design.html ( replace every dash '-' with an underscore '_')
enum QtFontAwesomeName {
icon_glass = 0xf000,
icon_music = 0xf001,
icon_search = 0xf002,
icon_envelope = 0xf003,
icon_heart = 0xf004,
icon_star = 0xf005,
icon_star_empty = 0xf006,
icon_user = 0xf007,
icon_film = 0xf008,
icon_th_large = 0xf009,
icon_th = 0xf00a,
icon_th_list = 0xf00b,
icon_ok = 0xf00c,
icon_remove = 0xf00d,
icon_zoom_in = 0xf00e,
icon_zoom_out = 0xf010,
icon_off = 0xf011,
icon_signal = 0xf012,
icon_cog = 0xf013,
icon_gear = icon_cog,
icon_trash = 0xf014,
icon_home = 0xf015,
icon_file_alt = 0xf016,
icon_time = 0xf017,
icon_road = 0xf018,
icon_download_alt = 0xf019,
icon_download = 0xf01a,
icon_upload = 0xf01b,
icon_inbox = 0xf01c,
icon_play_circle = 0xf01d,
icon_repeat = 0xf01e,
/* \f020 doesn't work in Safari. all shifted one down */
icon_refresh = 0xf021,
icon_list_alt = 0xf022,
icon_lock = 0xf023,
icon_flag = 0xf024,
icon_headphones = 0xf025,
icon_volume_off = 0xf026,
icon_volume_down = 0xf027,
icon_volume_up = 0xf028,
icon_qrcode = 0xf029,
icon_barcode = 0xf02a,
icon_tag = 0xf02b,
icon_tags = 0xf02c,
icon_book = 0xf02d,
icon_bookmark = 0xf02e,
icon_print = 0xf02f,
icon_camera = 0xf030,
icon_font = 0xf031,
icon_bold = 0xf032,
icon_italic = 0xf033,
icon_text_height = 0xf034,
icon_text_width = 0xf035,
icon_align_left = 0xf036,
icon_align_center = 0xf037,
icon_align_right = 0xf038,
icon_align_justify = 0xf039,
icon_list = 0xf03a,
icon_indent_left = 0xf03b,
icon_indent_right = 0xf03c,
icon_facetime_video = 0xf03d,
icon_picture = 0xf03e,
icon_pencil = 0xf040,
icon_map_marker = 0xf041,
icon_adjust = 0xf042,
icon_tint = 0xf043,
icon_edit = 0xf044,
icon_share = 0xf045,
icon_check = 0xf046,
icon_move = 0xf047,
icon_step_backward = 0xf048,
icon_fast_backward = 0xf049,
icon_backward = 0xf04a,
icon_play = 0xf04b,
icon_pause = 0xf04c,
icon_stop = 0xf04d,
icon_forward = 0xf04e,
icon_fast_forward = 0xf050,
icon_step_forward = 0xf051,
icon_eject = 0xf052,
icon_chevron_left = 0xf053,
icon_chevron_right = 0xf054,
icon_plus_sign = 0xf055,
icon_minus_sign = 0xf056,
icon_remove_sign = 0xf057,
icon_ok_sign = 0xf058,
icon_question_sign = 0xf059,
icon_info_sign = 0xf05a,
icon_screenshot = 0xf05b,
icon_remove_circle = 0xf05c,
icon_ok_circle = 0xf05d,
icon_ban_circle = 0xf05e,
icon_arrow_left = 0xf060,
icon_arrow_right = 0xf061,
icon_arrow_up = 0xf062,
icon_arrow_down = 0xf063,
icon_share_alt = 0xf064,
icon_resize_full = 0xf065,
icon_resize_small = 0xf066,
icon_plus = 0xf067,
icon_minus = 0xf068,
icon_asterisk = 0xf069,
icon_exclamation_sign = 0xf06a,
icon_gift = 0xf06b,
icon_leaf = 0xf06c,
icon_fire = 0xf06d,
icon_eye_open = 0xf06e,
icon_eye_close = 0xf070,
icon_warning_sign = 0xf071,
icon_plane = 0xf072,
icon_calendar = 0xf073,
icon_random = 0xf074,
icon_comment = 0xf075,
icon_magnet = 0xf076,
icon_chevron_up = 0xf077,
icon_chevron_down = 0xf078,
icon_retweet = 0xf079,
icon_shopping_cart = 0xf07a,
icon_folder_close = 0xf07b,
icon_folder_open = 0xf07c,
icon_resize_vertical = 0xf07d,
icon_resize_horizontal = 0xf07e,
icon_bar_chart = 0xf080,
icon_twitter_sign = 0xf081,
icon_facebook_sign = 0xf082,
icon_camera_retro = 0xf083,
icon_key = 0xf084,
icon_cogs = 0xf085,
icon_gears = icon_cogs,
icon_comments = 0xf086,
icon_thumbs_up_alt = 0xf087,
icon_thumbs_down_alt = 0xf088,
icon_star_half = 0xf089,
icon_heart_empty = 0xf08a,
icon_signout = 0xf08b,
icon_linkedin_sign = 0xf08c,
icon_pushpin = 0xf08d,
icon_external_link = 0xf08e,
icon_signin = 0xf090,
icon_trophy = 0xf091,
icon_github_sign = 0xf092,
icon_upload_alt = 0xf093,
icon_lemon = 0xf094,
icon_phone = 0xf095,
icon_check_empty = 0xf096,
icon_bookmark_empty = 0xf097,
icon_phone_sign = 0xf098,
icon_twitter = 0xf099,
icon_facebook = 0xf09a,
icon_github = 0xf09b,
icon_unlock = 0xf09c,
icon_credit_card = 0xf09d,
icon_rss = 0xf09e,
icon_hdd = 0xf0a0,
icon_bullhorn = 0xf0a1,
icon_bell = 0xf0a2,
icon_certificate = 0xf0a3,
icon_hand_right = 0xf0a4,
icon_hand_left = 0xf0a5,
icon_hand_up = 0xf0a6,
icon_hand_down = 0xf0a7,
icon_circle_arrow_left = 0xf0a8,
icon_circle_arrow_right = 0xf0a9,
icon_circle_arrow_up = 0xf0aa,
icon_circle_arrow_down = 0xf0ab,
icon_globe = 0xf0ac,
icon_wrench = 0xf0ad,
icon_tasks = 0xf0ae,
icon_filter = 0xf0b0,
icon_briefcase = 0xf0b1,
icon_fullscreen = 0xf0b2,
icon_group = 0xf0c0,
icon_link = 0xf0c1,
icon_cloud = 0xf0c2,
icon_beaker = 0xf0c3,
icon_cut = 0xf0c4,
icon_copy = 0xf0c5,
icon_paper_clip = 0xf0c6,
icon_save = 0xf0c7,
icon_sign_blank = 0xf0c8,
icon_reorder = 0xf0c9,
icon_list_ul = 0xf0ca,
icon_list_ol = 0xf0cb,
icon_strikethrough = 0xf0cc,
icon_underline = 0xf0cd,
icon_table = 0xf0ce,
icon_magic = 0xf0d0,
icon_truck = 0xf0d1,
icon_pinterest = 0xf0d2,
icon_pinterest_sign = 0xf0d3,
icon_google_plus_sign = 0xf0d4,
icon_google_plus = 0xf0d5,
icon_money = 0xf0d6,
icon_caret_down = 0xf0d7,
icon_caret_up = 0xf0d8,
icon_caret_left = 0xf0d9,
icon_caret_right = 0xf0da,
icon_columns = 0xf0db,
icon_sort = 0xf0dc,
icon_sort_down = 0xf0dd,
icon_sort_up = 0xf0de,
icon_envelope_alt = 0xf0e0,
icon_linkedin = 0xf0e1,
icon_undo = 0xf0e2,
icon_legal = 0xf0e3,
icon_dashboard = 0xf0e4,
icon_comment_alt = 0xf0e5,
icon_comments_alt = 0xf0e6,
icon_bolt = 0xf0e7,
icon_sitemap = 0xf0e8,
icon_umbrella = 0xf0e9,
icon_paste = 0xf0ea,
icon_lightbulb = 0xf0eb,
icon_exchange = 0xf0ec,
icon_cloud_download = 0xf0ed,
icon_cloud_upload = 0xf0ee,
icon_user_md = 0xf0f0,
icon_stethoscope = 0xf0f1,
icon_suitcase = 0xf0f2,
icon_bell_alt = 0xf0f3,
icon_coffee = 0xf0f4,
icon_food = 0xf0f5,
icon_file_text_alt = 0xf0f6,
icon_building = 0xf0f7,
icon_hospital = 0xf0f8,
icon_ambulance = 0xf0f9,
icon_medkit = 0xf0fa,
icon_fighter_jet = 0xf0fb,
icon_beer = 0xf0fc,
icon_h_sign = 0xf0fd,
icon_plus_sign_alt = 0xf0fe,
icon_double_angle_left = 0xf100,
icon_double_angle_right = 0xf101,
icon_double_angle_up = 0xf102,
icon_double_angle_down = 0xf103,
icon_angle_left = 0xf104,
icon_angle_right = 0xf105,
icon_angle_up = 0xf106,
icon_angle_down = 0xf107,
icon_desktop = 0xf108,
icon_laptop = 0xf109,
icon_tablet = 0xf10a,
icon_mobile_phone = 0xf10b,
icon_circle_blank = 0xf10c,
icon_quote_left = 0xf10d,
icon_quote_right = 0xf10e,
icon_spinner = 0xf110,
icon_circle = 0xf111,
icon_mail_reply = 0xf112,
icon_reply = icon_mail_reply,
icon_github_alt = 0xf113,
icon_folder_close_alt = 0xf114,
icon_folder_open_alt = 0xf115,
icon_expand_alt = 0xf116,
icon_collapse_alt = 0xf117,
icon_smile = 0xf118,
icon_frown = 0xf119,
icon_meh = 0xf11a,
icon_gamepad = 0xf11b,
icon_keyboard = 0xf11c,
icon_flag_alt = 0xf11d,
icon_flag_checkered = 0xf11e,
icon_terminal = 0xf120,
icon_code = 0xf121,
icon_reply_all = 0xf122,
icon_mail_reply_all = icon_reply_all,
icon_star_half_full = 0xf123,
icon_star_half_empty = icon_star_half_full,
icon_location_arrow = 0xf124,
icon_crop = 0xf125,
icon_code_fork = 0xf126,
icon_unlink = 0xf127,
icon_question = 0xf128,
icon_info = 0xf129,
icon_exclamation = 0xf12a,
icon_superscript = 0xf12b,
icon_subscript = 0xf12c,
icon_eraser = 0xf12d,
icon_puzzle_piece = 0xf12e,
icon_microphone = 0xf130,
icon_microphone_off = 0xf131,
icon_shield = 0xf132,
icon_calendar_empty = 0xf133,
icon_fire_extinguisher = 0xf134,
icon_rocket = 0xf135,
icon_maxcdn = 0xf136,
icon_chevron_sign_left = 0xf137,
icon_chevron_sign_right = 0xf138,
icon_chevron_sign_up = 0xf139,
icon_chevron_sign_down = 0xf13a,
icon_html5 = 0xf13b,
icon_css3 = 0xf13c,
icon_anchor = 0xf13d,
icon_unlock_alt = 0xf13e,
icon_bullseye = 0xf140,
icon_ellipsis_horizontal = 0xf141,
icon_ellipsis_vertical = 0xf142,
icon_rss_sign = 0xf143,
icon_play_sign = 0xf144,
icon_ticket = 0xf145,
icon_minus_sign_alt = 0xf146,
icon_check_minus = 0xf147,
icon_level_up = 0xf148,
icon_level_down = 0xf149,
icon_check_sign = 0xf14a,
icon_edit_sign = 0xf14b,
icon_external_link_sign = 0xf14c,
icon_share_sign = 0xf14d,
// v3.2.0
icon_compass = 0xf14e,
icon_collapse = 0xf150,
icon_collapse_top = 0xf151,
icon_expand = 0xf152,
icon_euro = 0xf153,
icon_eur = 0xf153,
icon_gbp = 0xf154,
icon_dollar = 0xf155,
icon_usd = icon_dollar,
icon_rupee = 0xf156,
icon_inr = icon_rupee,
icon_yen = 0xf157,
icon_jpy = icon_yen,
icon_renminbi = 0xf158,
icon_cny = icon_renminbi,
icon_won = 0xf159,
icon_krw = icon_won,
icon_bitcoin = 0xf15a,
icon_btc = icon_bitcoin,
icon_file = 0xf15b,
icon_file_text = 0xf15c,
icon_sort_by_alphabet = 0xf15d,
icon_sort_by_alphabet_alt = 0xf15e,
icon_sort_by_attributes = 0xf160,
icon_sort_by_attributes_alt = 0xf161,
icon_sort_by_order = 0xf162,
icon_sort_by_order_alt = 0xf163,
icon_thumbs_up = 0xf164,
icon_thumbs_down = 0xf165,
icon_youtube_sign = 0xf166,
icon_youtube = 0xf167,
icon_xing = 0xf168,
icon_xing_sign = 0xf169,
icon_youtube_play = 0xf16a,
icon_dropbox = 0xf16b,
icon_stackexchange = 0xf16c,
icon_instagram = 0xf16d,
icon_flickr = 0xf16e,
icon_adn = 0xf170,
icon_bitbucket = 0xf171,
icon_bitbucket_sign = 0xf172,
icon_tumblr = 0xf173,
icon_tumblr_sign = 0xf174,
icon_long_arrow_down = 0xf175,
icon_long_arrow_up = 0xf176,
icon_long_arrow_left = 0xf177,
icon_long_arrow_right = 0xf178,
icon_apple = 0xf179,
icon_windows = 0xf17a,
icon_android = 0xf17b,
icon_linux = 0xf17c,
icon_dribble = 0xf17d,
icon_skype = 0xf17e,
icon_foursquare = 0xf180,
icon_trello = 0xf181,
icon_female = 0xf182,
icon_male = 0xf183,
icon_gittip = 0xf184,
icon_sun = 0xf185,
icon_moon = 0xf186,
icon_archive = 0xf187,
icon_bug = 0xf188,
icon_vk = 0xf189,
icon_weibo = 0xf18a,
icon_renren = 0xf18b
/// You can use the names on the page http://fortawesome.github.io/Font-Awesome/design.html
enum class fa {
glass = 0xf000,
music = 0xf001,
search = 0xf002,
envelopeo = 0xf003,
heart = 0xf004,
star = 0xf005,
staro = 0xf006,
user = 0xf007,
film = 0xf008,
thlarge = 0xf009,
th = 0xf00a,
thlist = 0xf00b,
check = 0xf00c,
times = 0xf00d,
searchplus = 0xf00e,
searchminus = 0xf010,
poweroff = 0xf011,
signal = 0xf012,
cog = 0xf013,
trasho = 0xf014,
home = 0xf015,
fileo = 0xf016,
clocko = 0xf017,
road = 0xf018,
download = 0xf019,
arrowcircleodown = 0xf01a,
arrowcircleoup = 0xf01b,
inbox = 0xf01c,
playcircleo = 0xf01d,
repeat = 0xf01e,
refresh = 0xf021,
listalt = 0xf022,
lock = 0xf023,
flag = 0xf024,
headphones = 0xf025,
volumeoff = 0xf026,
volumedown = 0xf027,
volumeup = 0xf028,
qrcode = 0xf029,
barcode = 0xf02a,
tag = 0xf02b,
tags = 0xf02c,
book = 0xf02d,
bookmark = 0xf02e,
print = 0xf02f,
camera = 0xf030,
font = 0xf031,
bold = 0xf032,
italic = 0xf033,
textheight = 0xf034,
textwidth = 0xf035,
alignleft = 0xf036,
aligncenter = 0xf037,
alignright = 0xf038,
alignjustify = 0xf039,
list = 0xf03a,
outdent = 0xf03b,
indent = 0xf03c,
videocamera = 0xf03d,
pictureo = 0xf03e,
pencil = 0xf040,
mapmarker = 0xf041,
adjust = 0xf042,
tint = 0xf043,
pencilsquareo = 0xf044,
sharesquareo = 0xf045,
checksquareo = 0xf046,
arrows = 0xf047,
stepbackward = 0xf048,
fastbackward = 0xf049,
backward = 0xf04a,
play = 0xf04b,
pause = 0xf04c,
stop = 0xf04d,
forward = 0xf04e,
fastforward = 0xf050,
stepforward = 0xf051,
eject = 0xf052,
chevronleft = 0xf053,
chevronright = 0xf054,
pluscircle = 0xf055,
minuscircle = 0xf056,
timescircle = 0xf057,
checkcircle = 0xf058,
questioncircle = 0xf059,
infocircle = 0xf05a,
crosshairs = 0xf05b,
timescircleo = 0xf05c,
checkcircleo = 0xf05d,
ban = 0xf05e,
arrowleft = 0xf060,
arrowright = 0xf061,
arrowup = 0xf062,
arrowdown = 0xf063,
share = 0xf064,
expand = 0xf065,
compress = 0xf066,
plus = 0xf067,
minus = 0xf068,
asterisk = 0xf069,
exclamationcircle = 0xf06a,
gift = 0xf06b,
leaf = 0xf06c,
fire = 0xf06d,
eye = 0xf06e,
eyeslash = 0xf070,
exclamationtriangle = 0xf071,
plane = 0xf072,
calendar = 0xf073,
random = 0xf074,
comment = 0xf075,
magnet = 0xf076,
chevronup = 0xf077,
chevrondown = 0xf078,
retweet = 0xf079,
shoppingcart = 0xf07a,
folder = 0xf07b,
folderopen = 0xf07c,
arrowsv = 0xf07d,
arrowsh = 0xf07e,
barcharto = 0xf080,
twittersquare = 0xf081,
facebooksquare = 0xf082,
cameraretro = 0xf083,
key = 0xf084,
cogs = 0xf085,
comments = 0xf086,
thumbsoup = 0xf087,
thumbsodown = 0xf088,
starhalf = 0xf089,
hearto = 0xf08a,
signout = 0xf08b,
linkedinsquare = 0xf08c,
thumbtack = 0xf08d,
externallink = 0xf08e,
signin = 0xf090,
trophy = 0xf091,
githubsquare = 0xf092,
upload = 0xf093,
lemono = 0xf094,
phone = 0xf095,
squareo = 0xf096,
bookmarko = 0xf097,
phonesquare = 0xf098,
twitter = 0xf099,
facebook = 0xf09a,
github = 0xf09b,
unlock = 0xf09c,
creditcard = 0xf09d,
rss = 0xf09e,
hddo = 0xf0a0,
bullhorn = 0xf0a1,
bell = 0xf0f3,
certificate = 0xf0a3,
handoright = 0xf0a4,
handoleft = 0xf0a5,
handoup = 0xf0a6,
handodown = 0xf0a7,
arrowcircleleft = 0xf0a8,
arrowcircleright = 0xf0a9,
arrowcircleup = 0xf0aa,
arrowcircledown = 0xf0ab,
globe = 0xf0ac,
wrench = 0xf0ad,
tasks = 0xf0ae,
filter = 0xf0b0,
briefcase = 0xf0b1,
arrowsalt = 0xf0b2,
users = 0xf0c0,
link = 0xf0c1,
cloud = 0xf0c2,
flask = 0xf0c3,
scissors = 0xf0c4,
fileso = 0xf0c5,
paperclip = 0xf0c6,
floppyo = 0xf0c7,
square = 0xf0c8,
bars = 0xf0c9,
listul = 0xf0ca,
listol = 0xf0cb,
strikethrough = 0xf0cc,
underline = 0xf0cd,
table = 0xf0ce,
magic = 0xf0d0,
truck = 0xf0d1,
pinterest = 0xf0d2,
pinterestsquare = 0xf0d3,
googleplussquare = 0xf0d4,
googleplus = 0xf0d5,
money = 0xf0d6,
caretdown = 0xf0d7,
caretup = 0xf0d8,
caretleft = 0xf0d9,
caretright = 0xf0da,
columns = 0xf0db,
sort = 0xf0dc,
sortasc = 0xf0dd,
sortdesc = 0xf0de,
envelope = 0xf0e0,
linkedin = 0xf0e1,
undo = 0xf0e2,
gavel = 0xf0e3,
tachometer = 0xf0e4,
commento = 0xf0e5,
commentso = 0xf0e6,
bolt = 0xf0e7,
sitemap = 0xf0e8,
umbrella = 0xf0e9,
clipboard = 0xf0ea,
lightbulbo = 0xf0eb,
exchange = 0xf0ec,
clouddownload = 0xf0ed,
cloudupload = 0xf0ee,
usermd = 0xf0f0,
stethoscope = 0xf0f1,
suitcase = 0xf0f2,
bello = 0xf0a2,
coffee = 0xf0f4,
cutlery = 0xf0f5,
filetexto = 0xf0f6,
buildingo = 0xf0f7,
hospitalo = 0xf0f8,
ambulance = 0xf0f9,
medkit = 0xf0fa,
fighterjet = 0xf0fb,
beer = 0xf0fc,
hsquare = 0xf0fd,
plussquare = 0xf0fe,
angledoubleleft = 0xf100,
angledoubleright = 0xf101,
angledoubleup = 0xf102,
angledoubledown = 0xf103,
angleleft = 0xf104,
angleright = 0xf105,
angleup = 0xf106,
angledown = 0xf107,
desktop = 0xf108,
laptop = 0xf109,
tablet = 0xf10a,
mobile = 0xf10b,
circleo = 0xf10c,
quoteleft = 0xf10d,
quoteright = 0xf10e,
spinner = 0xf110,
circle = 0xf111,
reply = 0xf112,
githubalt = 0xf113,
foldero = 0xf114,
folderopeno = 0xf115,
smileo = 0xf118,
frowno = 0xf119,
meho = 0xf11a,
gamepad = 0xf11b,
keyboardo = 0xf11c,
flago = 0xf11d,
flagcheckered = 0xf11e,
terminal = 0xf120,
code = 0xf121,
replyall = 0xf122,
mailreplyall = 0xf122,
starhalfo = 0xf123,
locationarrow = 0xf124,
crop = 0xf125,
codefork = 0xf126,
chainbroken = 0xf127,
question = 0xf128,
info = 0xf129,
exclamation = 0xf12a,
superscript = 0xf12b,
subscript = 0xf12c,
eraser = 0xf12d,
puzzlepiece = 0xf12e,
microphone = 0xf130,
microphoneslash = 0xf131,
shield = 0xf132,
calendaro = 0xf133,
fireextinguisher = 0xf134,
rocket = 0xf135,
maxcdn = 0xf136,
chevroncircleleft = 0xf137,
chevroncircleright = 0xf138,
chevroncircleup = 0xf139,
chevroncircledown = 0xf13a,
html5 = 0xf13b,
css3 = 0xf13c,
anchor = 0xf13d,
unlockalt = 0xf13e,
bullseye = 0xf140,
ellipsish = 0xf141,
ellipsisv = 0xf142,
rsssquare = 0xf143,
playcircle = 0xf144,
ticket = 0xf145,
minussquare = 0xf146,
minussquareo = 0xf147,
levelup = 0xf148,
leveldown = 0xf149,
checksquare = 0xf14a,
pencilsquare = 0xf14b,
externallinksquare = 0xf14c,
sharesquare = 0xf14d,
compass = 0xf14e,
caretsquareodown = 0xf150,
caretsquareoup = 0xf151,
caretsquareoright = 0xf152,
eur = 0xf153,
gbp = 0xf154,
usd = 0xf155,
inr = 0xf156,
jpy = 0xf157,
rub = 0xf158,
krw = 0xf159,
btc = 0xf15a,
file = 0xf15b,
filetext = 0xf15c,
sortalphaasc = 0xf15d,
sortalphadesc = 0xf15e,
sortamountasc = 0xf160,
sortamountdesc = 0xf161,
sortnumericasc = 0xf162,
sortnumericdesc = 0xf163,
thumbsup = 0xf164,
thumbsdown = 0xf165,
youtubesquare = 0xf166,
youtube = 0xf167,
xing = 0xf168,
xingsquare = 0xf169,
youtubeplay = 0xf16a,
dropbox = 0xf16b,
stackoverflow = 0xf16c,
instagram = 0xf16d,
flickr = 0xf16e,
adn = 0xf170,
bitbucket = 0xf171,
bitbucketsquare = 0xf172,
tumblr = 0xf173,
tumblrsquare = 0xf174,
longarrowdown = 0xf175,
longarrowup = 0xf176,
longarrowleft = 0xf177,
longarrowright = 0xf178,
appleicon = 0xf179,
windowsicon = 0xf17a,
androidicon = 0xf17b,
linuxicon = 0xf17c,
dribbble = 0xf17d,
skype = 0xf17e,
foursquare = 0xf180,
trello = 0xf181,
female = 0xf182,
male = 0xf183,
gittip = 0xf184,
suno = 0xf185,
moono = 0xf186,
archive = 0xf187,
bug = 0xf188,
vk = 0xf189,
weibo = 0xf18a,
renren = 0xf18b,
pagelines = 0xf18c,
stackexchange = 0xf18d,
arrowcircleoright = 0xf18e,
arrowcircleoleft = 0xf190,
caretsquareoleft = 0xf191,
dotcircleo = 0xf192,
wheelchair = 0xf193,
vimeosquare = 0xf194,
tryicon = 0xf195,
plussquareo = 0xf196
};
@ -442,13 +410,13 @@ public:
void init( const QString& fontname );
bool initFontAwesome();
void addNamedCodepoint( const QString& name, int codePoint );
QHash<QString,int> namedCodePoints() { return namedCodepoints_; }
void addNamedCodepoint( const QString& name, fa codePoint );
QHash<QString,fa> namedCodePoints() { return namedCodepoints_; }
void setDefaultOption( const QString& name, const QVariant& value );
QVariant defaultOption( const QString& name );
QIcon icon( int character, const QVariantMap& options = QVariantMap() );
QIcon icon( fa character, const QVariantMap& options = QVariantMap() );
QIcon icon( const QString& name, const QVariantMap& options = QVariantMap() );
QIcon icon(QtAwesomeIconPainter* painter, const QVariantMap& optionMap = QVariantMap() );
@ -461,7 +429,7 @@ public:
private:
QString fontName_; ///< The font name used for this map
QHash<QString,int> namedCodepoints_; ///< A map with names mapped to code-points
QHash<QString,fa> namedCodepoints_; ///< A map with names mapped to code-points
QHash<QString, QtAwesomeIconPainter*> painterMap_; ///< A map of custom painters
QVariantMap defaultOptions_; ///< The default icon options

View File

@ -6,7 +6,7 @@
TARGET = QtAwesome
TEMPLATE = lib
CONFIG += staticlib
CONFIG += staticlib c++11
SOURCES += QtAwesome.cpp
HEADERS += QtAwesome.h

View File

@ -1,5 +1,5 @@
<RCC>
<qresource prefix="/">
<file>fonts/fontawesome.ttf</file>
<file>fonts/fontawesome-4.0.3.ttf</file>
</qresource>
</RCC>

View File

@ -10,6 +10,7 @@ greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
TARGET = QtAwesomeSample
TEMPLATE = app
CONFIG += c++11
SOURCES += main.cpp

View File

@ -18,7 +18,7 @@ int main(int argc, char *argv[])
awesome->initFontAwesome();
// a simple beer button
QPushButton* beerButton = new QPushButton( awesome->icon( icon_beer ), "Cheers!" );
QPushButton* beerButton = new QPushButton( awesome->icon( fa::star ), "Cheers!" );
w.setCentralWidget( beerButton );
w.show();

View File

@ -45,10 +45,10 @@ Example
QtAwesome* awesome = new QtAwesome( qApp );
awesome->initFontAwesome();
// Next create your icon with the help of the icon-enumeration: (all dashes are replaced by underscores)
QPushButton* beerButton new QPushButton( awesome->icon( icon_beer ), "Cheers!" );
// Next create your icon with the help of the icon-enumeration (no dashes):
QPushButton* beerButton new QPushButton( awesome->icon( fa::beer ), "Cheers!" );
// You can also use 'string' names to access the icons. (The string version omits the 'icon-' prefix )
// You can also use 'string' names to access the icons. (The string version omits the 'fa-' or 'icon-' prefix and has no dashes )
QPushButton* coffeeButton new QPushButton( awesome->icon( "coffee" ), "Black please!" );
// When you create an icon you can supply some options for your icons:
@ -56,14 +56,14 @@ QPushButton* coffeeButton new QPushButton( awesome->icon( "coffee" ), "Black ple
QVariantMap options;
options.insert( "color" , QColor(255,0,0) );
QPushButton* musicButton = new QPushButton( awesome->icon( icon_music, options ), "Music" );
QPushButton* musicButton = new QPushButton( awesome->icon( fa::music, options ), "Music" );
// You can also change the default options.
// for example if you always would like to have green icons you could call)
awesome->setDefaultOption( "color-disabled", QColor(0,255,0) );
// You can also directly render a label with this font
QLabel* label = new QLabel( QChar( icon_group ) );
QLabel* label = new QLabel( QChar( fa::group ) );
label->setFont( awesome->font(16) );
```
@ -81,7 +81,7 @@ public:
{
int drawSize = qRound(rectIn.height()*0.5);
int offset = rectIn.height() / 4;
QChar chr = QChar( icon_plus );
QChar chr = QChar( static_cast<int>(fa::plus) );
painter->setFont( awesome->font( drawSize ) );
@ -124,7 +124,7 @@ setDefaultOption( "scale-factor", 0.9 );
you could supply the following option.
```c++
options.insert("text-selected", QString( icon_lock ) );
options.insert("text-selected", QString( fa::lock ) );
```
License