问题标签 [gaps-in-visuals]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
426 浏览

apache-flex - Flex:图形之间的间隙

我有一个包含 2 个图形的组,我将组的垂直布局中的间隙设置为 0,但 2 个图形之间仍然存在 1 个像素的间隙。知道如何摆脱这个吗?

0 投票
1 回答
4158 浏览

css - 页面顶部和页面上的第一个 div 之间的气隙

这是示例html:

我想知道为什么在这种情况和类似的情况下,大多数(所有?)浏览器的页面顶部和包含文本的 div 之间存在间隙。我知道我可以做一个“顶部:-y px”,但我知道我做错了什么......

0 投票
1 回答
169 浏览

uiview - UIView 添加子视图间隙

我知道这可能是一个愚蠢的问题。但我正在 xcode 3、ios 5 中设计一个单视图应用程序。以编程方式添加子视图和图像视图以占据整个屏幕。但它在屏幕上我的视图底部显示了一个小间隙。不知道为什么。这是代码。有什么建议吗?

0 投票
1 回答
2726 浏览

objective-c - 水平分页的 UIScrollView 与每个视图之间的间隙 - 视图不居中

Apple 的 WWDC 2010 教程视频“Designing Apps with Scroll Views”在 iOS 4 中运行良好,但在 iOS 5 中页面不居中:

在此处输入图像描述

看起来

在 iOS 5 中不起作用。

我的代码如下:

我能做些什么?

0 投票
1 回答
427 浏览

java - java jframe和ImagePanel之间的差距

图像我有一个添加三个对象的 JLayeredPane,问题是 backgroundImage 当应用程序运行时,jframe 和顶部的背景图像之间存在间隙,我设置为(0,0)无论我改变什么间隙仍然那里(我想消除差距)。如果我复制 backgroundImage 类并将其放在另一个文件/类中,则间隙不存在。谁能帮忙?

0 投票
2 回答
25592 浏览

java - Java FlowLayout - Margin/padding of specific elements?

I am very new to Swing, and I'm trying to make a GUI. Using Netbeans' GUI creator thing, I managed to make something I liked. But it makes me feel bad that I used the editor for this, so now I am trying to make the same design using code. Here is a picture of what I am trying to make: what I want to make Right now I am just focusing on creating the "Criteria" section (yes I know I spelled it wrong in the picture) Here is what I currently have so far: what I currently have I've highlighted in red where I want to increase the margin:

  • Between the right of the text boxes and left of the labels
  • Between the top of the Criteria panel and the JFrame
  • Between the left and right sides of the panel and the JFrame

I come from web development where increasing the margins is what I want to do. If this is incorrect terminology, please inform me. Here is the code I am currently using:

I don't know how I would add margin to these components, so help would be very much appreciated. If I cannot achieve this effect with FlowLayout, then please tell me what I should use instead.

0 投票
2 回答
775 浏览

iphone - UIScrollView 的子视图之间的差距

我有 UIScrollView 的两个子视图。一个是textView,另一个是tableView。我根据其内容使 textview 的高度灵活,但我有一个问题。如果 textview 中的文本(也就是解析出来的数据)很小,那么 textview 和 tableview 之间就有很大的差距。或者如果文本太大,那么它会覆盖 tableview。无论文本视图的内容量如何,如何在 textview 和 tableview 之间保持相同的差距?这一切都在IB中完成。谢谢。

0 投票
1 回答
128 浏览

html - 我将 html、body 和容器 div 设置为 100% 高度,但页面顶部仍然存在间隙?

}

伙计们怎么了?是不是因为我读到的 utf-8 会留下没有宽度的垂直间隙,idk 有点在黑暗中拍摄。

0 投票
3 回答
2955 浏览

java - 如何消除 MigLayout 中两个单元格之间的垂直间隙?

非常简单的问题:如何消除包含两者的两个单元格之间的垂直间隙JCheckBox?我用红色边框标记了图片中的空白。

差距

这是代码:

0 投票
1 回答
392 浏览

css - 自动扩大导航按钮之间的间隙 - CSS

我正在使用 CSS 进行顶部导航。一些按钮浮动到左侧,而一些按钮浮动到右侧。中间有空的间隙按钮。如何使该间隙自动扩展,以便整个顶部导航占据页面的 100%?

这是示例图像的链接:

HTML:

CSS:

CSS/HTML 链接:http: //jsfiddle.net/xRCqx/