设为首页收藏本站|繁體中文

Project1

 找回密码
 注册会员
搜索

我换了对话框的图片皮肤,但是文字出框了怎么办

查看数: 214 | 评论数: 1 | 收藏 1
关灯 | 提示:支持键盘翻页<-左 右->
    组图打开中,请稍候......
发布时间: 2024-4-1 19:33

正文摘要:

如图,文字左边超出了框,能不能把对话框里面针对文本的内边距缩小. 用的是Drill大佬的插件

回复

505681468 发表于 2024-4-1 20:49:33
本帖最后由 505681468 于 2024-4-1 20:54 编辑

可能是这几个?
padding好像没有左右上下边距的单独设定,所以设定后的 contents 位置 x=y。
如果不符合需求的话,可能需要自定义了


  1. // 创建 contents
  2. Window_Base.prototype.createContents = function() {
  3.     this.contents = new Bitmap(this.contentsWidth(), this.contentsHeight());
  4.     this.resetFontSettings();
  5. };
  6. // 窗口内填充距离
  7. Window_Base.prototype.standardPadding = function() {
  8.     return 18;
  9. };
  10. // contents 宽度
  11. Window_Base.prototype.contentsWidth = function() {
  12.     return this.width - this.standardPadding() * 2;
  13. };
  14. // contents 高度
  15. Window_Base.prototype.contentsHeight = function() {
  16.     return this.height - this.standardPadding() * 2;
  17. };
  18. // contents 位置刷新
  19. Window.prototype._refreshContents = function() {
  20.     this._windowContentsSprite.move(this.padding, this.padding);
  21. };
复制代码
拿上你的纸笔,建造一个属于你的梦想世界,加入吧。
 注册会员
找回密码

站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作

GMT+8, 2024-5-26 07:57

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表