【问题标题】:Javafx8 ProgressIndicator not showing in UbuntuJavafx 8 进度指示器未在 Ubuntu 中显示
【发布时间】:2016-06-08 13:08:00
【问题描述】:

我开发了一个跨平台应用程序,其中包括一个 javafx.stage.Popup 对象,上面有 javafx.scene.control.ProgressIndicator。它在 Windows 上显示,但在 Ubuntu 中没有(仅显示百分比),有没有人遇到过这样的问题

【问题讨论】:

  • 请提供simple example 证明问题。
  • popup = new Popup(); popup.setWidth(ConfigClass.POPUP_WIDTH); popup.setHeight(ConfigClass.POPUP_HEIGHT); popUpHBox = new AnchorPane(); popUpHBox.setPrefWidth(ConfigClass.SCREENSHOT_POPUP_WIDTH); popUpHBox.setPrefHeight(ConfigClass.SCREENSHOT_POPUP_HEIGHT); timer = new ProgressIndicator(timer_progress); timer.setPrefWidth(105); timer.setPrefHeight(88); timer.setLayoutX(105); timer.setLayoutY(56); popUpHBox.getChildren().addAll(timer); popup.getContent().addAll(popUpHBox); popup.show(ViewClass.getStage()); popup.setAutoHide(false); popup.setAutoFix(true);

标签: linux javafx-8 ubuntu-15.04 progress-indicator


【解决方案1】:

我通过将 progress-color 属性赋予进度指示器来修复它,Linux 只是无法为该组件分配默认背景颜色

【讨论】:

    猜你喜欢
    • 2018-07-26
    • 1970-01-01
    • 2011-09-29
    • 1970-01-01
    • 1970-01-01
    • 2018-12-17
    • 1970-01-01
    • 1970-01-01
    • 2020-02-10
    相关资源
    最近更新 更多