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

Optimize the code of BMFont and LetterFont #5223

Merged
merged 2 commits into from Aug 26, 2019

Conversation

@caryliu1999
Copy link
Contributor

commented Aug 22, 2019

Re: cocos-creator/2d-tasks#198

2.2分支做的优化修改 #5145,由于2.2版本的assembler层面做了重构,与2.1版本差别较大,单独修改合并到2.1.3分支。

Changes:
1.优化LetterFont的代码,复用BMFont,删除冗余代码。
2.支持CHAR模式的Label使用SHRINK自动布局。
3.优化BMFont字符数量较大时,使用SHRINK的卡顿问题。

@2youyou2 2youyou2 merged commit 7cc6f09 into cocos-creator:v2.1.3 Aug 26, 2019
1 check passed
1 check passed
ci/circleci: test Your tests passed on CircleCI!
Details
jareguo added a commit that referenced this pull request Aug 28, 2019
…elease

* commit '95bb66312892cb63b43c3dff942a221de6fafdb5':
  refine engine prepare (#5261)
  space added when atlas calculates next y position. (#5242)
  fixed animation (#5246)
  fix scrollview bar display bug (#5249)
  fixed search skeleton animation clip when no model provided (#5258)
  fix RenderComponent properties animatable for 2d-tasks/issues/1755 (#5253)
  fix error when run in wechat develop platform (#5185) (#5248)
  Optimize the code of BMFont and LetterFont (#5223)
  Fix getParameter call inside texture update (#5198)
  refine editbox css-in-js (#5203)
  improve scrollview inspector panel (#5215)
  fixed mesh sprite (#5195)
  add CCView extends EventTarget api (#5205)
  rm _rotationX and _rotationY (#5197)
  fix restore rotation invalid (#5188)
  change comments of code in CCComponentEventHandler and CCSlider (#5178)

# Conflicts:
#	cocos2d/core/mesh/CCMeshRenderer.js
#	cocos2d/core/renderer/utils/label/bmfont.js
#	cocos2d/core/renderer/utils/label/letter-font.js
#	cocos2d/core/renderer/utils/label/ttf.js
#	cocos2d/core/renderer/utils/utils.js
#	cocos2d/core/renderer/webgl/assemblers/label/2d/letter.js
#	cocos2d/core/renderer/webgl/assemblers/label/index.js
#	cocos2d/core/renderer/webgl/assemblers/sprite/2d/mesh.js
#	test/qunit/unit-es5/test-serialize-node.js
jareguo added a commit that referenced this pull request Aug 28, 2019
* v2.2.0-release: (27 commits)
  add dynamicPack property to texture (#5125)
  improve cc._throw code (#5208)
  refine engine prepare (#5261)
  space added when atlas calculates next y position. (#5242)
  fixed animation (#5246)
  fix scrollview bar display bug (#5249)
  fixed search skeleton animation clip when no model provided (#5258)
  fix RenderComponent properties animatable for 2d-tasks/issues/1755 (#5253)
  fix error when run in wechat develop platform (#5185) (#5248)
  Fix tiledlayer node rebuild bug (#5247)
  Optimize the code of BMFont and LetterFont (#5223)
  Fix getParameter call inside texture update (#5198)
  refine editbox css-in-js (#5203)
  improve scrollview inspector panel (#5215)
  fix 2.2.0 opacity dirty bug (#5240)
  refine find frame index logic (#5220)
  improve sprite animation performance (#5210)
  optimize animation (#5211)
  fixed load sprite
  fixed mesh sprite (#5195)
  ...

# Conflicts:
#	cocos2d/core/CCGame.js
jareguo added a commit that referenced this pull request Aug 28, 2019
* v2.2.0: (63 commits)
  add dynamicPack property to texture (#5125)
  improve cc._throw code (#5208)
  refine engine prepare (#5261)
  space added when atlas calculates next y position. (#5242)
  V2.2.0 add gulp task name (#5181)
  fixed animation (#5246)
  fix scrollview bar display bug (#5249)
  fixed search skeleton animation clip when no model provided (#5258)
  fix RenderComponent properties animatable for 2d-tasks/issues/1755 (#5253)
  fix error when run in wechat develop platform (#5185) (#5248)
  Fix tiledlayer node rebuild bug (#5247)
  Optimize the code of BMFont and LetterFont (#5223)
  Fix getParameter call inside texture update (#5198)
  refine editbox css-in-js (#5203)
  improve scrollview inspector panel (#5215)
  fix 2.2.0 opacity dirty bug (#5240)
  add dynamicPack property to texture (#5125)
  refine find frame index logic (#5220)
  improve sprite animation performance (#5210)
  optimize animation (#5211)
  ...

# Conflicts:
#	cocos2d/core/CCGame.js
#	cocos2d/core/assets/CCTexture2D.js
#	cocos2d/core/components/CCLabel.js
#	cocos2d/core/mesh/CCMesh.js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.