提交 da1381b1 编写于 作者: S suwenxiang

Description: Mini platform GN + iccarm compile and build

IssueNo: https://gitee.com/openharmony/graphic_ui/issues/I5IS4P
Feature or Bugfix: Feature
Binary Source: No
Signed-off-by: Nsuwenxiang <suwenxiang@huawei.com>
上级 8fb14c09
......@@ -224,6 +224,7 @@ lite_library("ui") {
"//third_party/bounds_checking_function:libsec_static",
"//third_party/freetype:freetype",
"//third_party/giflib:libgif",
"//third_party/icu/icu4c/source/common:icu_font",
"//third_party/libjpeg:libjpeg",
"//third_party/libpng:libpng",
"//third_party/qrcodegen:qrcodegen",
......@@ -263,9 +264,17 @@ lite_library("ui") {
public_deps = [ "//foundation/graphic/utils:lite_graphic_utils" ]
public_configs = [ ":graphic_define_config" ]
cflags = [
"-Wall",
"-fno-exceptions",
]
cflags_cc = cflags
if (board_toolchain_type != "iccarm") {
cflags = [
"-Wall",
"-fno-exceptions",
]
cflags_cc = cflags
} else {
cflags = [
"--diag_suppress",
"Pa093,Pa137,Pe177,Pe186,Pe226,Pe366,Pe367,Pe550",
]
cflags_cc = cflags
}
}
......@@ -61,7 +61,7 @@ public:
const SavedImage* savedImage,
GraphicsControlBlock gcb,
const ColorMapObject* colorMap) const;
const void OpenGifFile(const char* src);
void OpenGifFile(const char* src);
void CloseGifFile();
private:
......@@ -83,7 +83,7 @@ private:
const char* src_;
};
const void GifImageAnimator::OpenGifFile(const char* src)
void GifImageAnimator::OpenGifFile(const char* src)
{
int error = D_GIF_SUCCEEDED;
GifFileType* gifFileType = DGifOpenFileName(src, &error);
......
......@@ -16,9 +16,7 @@
#include "font/ui_font_adaptor.h"
#include "common/typed_text.h"
#include "graphic_config.h"
#if ENABLE_ICU
#include "font/ui_line_break.h"
#endif
#if ENABLE_SHAPING
#include "font/ui_text_shaping.h"
#endif
......
......@@ -548,10 +548,6 @@ public:
*/
void SetLineDash(float* lineDashs, const uint32_t ndash)
{
if (ndash < 0) {
GRAPHIC_LOGE("SetLineDash fail,because ndash < =0");
return;
}
ClearLineDash();
if (lineDashs == nullptr || ndash == 0) {
return;
......@@ -1451,12 +1447,14 @@ public:
if (isStroke) {
if (paint.GetStyle() == Paint::STROKE_STYLE ||
paint.GetStyle() == Paint::STROKE_FILL_STYLE) {
ChangeColor(color, paint.GetStrokeColor(), paint.GetStrokeColor().alpha * paint.GetGlobalAlpha());
ChangeColor(color, paint.GetStrokeColor(),
static_cast<uint8_t>(paint.GetStrokeColor().alpha * paint.GetGlobalAlpha()));
}
} else {
if (paint.GetStyle() == Paint::FILL_STYLE ||
paint.GetStyle() == Paint::STROKE_FILL_STYLE) {
ChangeColor(color, paint.GetFillColor(), paint.GetFillColor().alpha * paint.GetGlobalAlpha());
ChangeColor(color, paint.GetFillColor(),
static_cast<uint8_t>(paint.GetFillColor().alpha * paint.GetGlobalAlpha()));
}
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册