gpt4 book ai didi

java - 如何解决 "No more handles exception", Eclipse Oxygen, Windowbuilder Pro

转载 作者:塔克拉玛干 更新时间:2023-11-02 23:33:36 25 4
gpt4 key购买 nike

我在 Debian Buster 下将 Eclipse Oxygen 与 WindowBuilder Pro 结合使用,当我想在设计选项卡中打开 .java 文件(带有 Swing JFrame)时,出现“Designer,No more handles”错误。之后,系统询问我是否要退出工作台,因为可能会出现更多 SWT 错误并且它可能会意外关闭。

单击“否”后,我仍然可以看到设计器,但它不会对任何试图改变 JFrame 的点击或移动使用react。

message 1 message 2

错误堆栈跟踪:

org.eclipse.swt.SWTError: No more handles
at org.eclipse.swt.SWT.error(SWT.java:4559)
at org.eclipse.swt.SWT.error(SWT.java:4448)
at org.eclipse.swt.SWT.error(SWT.java:4419)
at org.eclipse.swt.graphics.Cursor.<init>(Cursor.java:180)
at org.eclipse.wb.draw2d.ICursorConstants.<clinit>(ICursorConstants.java:98)
at org.eclipse.wb.gef.graphical.tools.MarqueeSelectionTool.<init>(MarqueeSelectionTool.java:61)
at org.eclipse.wb.core.editor.palette.model.entry.MarqueeSelectionToolEntryInfo.<init>(MarqueeSelectionToolEntryInfo.java:29)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at java.lang.Class.newInstance(Class.java:442)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:184)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.wb.internal.core.editor.palette.PaletteManager$6.run(PaletteManager.java:443)
at org.eclipse.wb.internal.core.utils.execution.ExecutionUtils.runLog(ExecutionUtils.java:106)
at org.eclipse.wb.internal.core.editor.palette.PaletteManager.processCategoryChild(PaletteManager.java:429)
at org.eclipse.wb.internal.core.editor.palette.PaletteManager.processPaletteChildren(PaletteManager.java:418)
at org.eclipse.wb.internal.core.editor.palette.PaletteManager.processCategory(PaletteManager.java:388)
at org.eclipse.wb.internal.core.editor.palette.PaletteManager.parseExtensionPalette(PaletteManager.java:360)
at org.eclipse.wb.internal.core.editor.palette.PaletteManager.access$0(PaletteManager.java:345)
at org.eclipse.wb.internal.core.editor.palette.PaletteManager$1.run(PaletteManager.java:139)
at org.eclipse.wb.internal.core.utils.execution.ExecutionUtils.runLog(ExecutionUtils.java:106)
at org.eclipse.wb.internal.core.editor.palette.PaletteManager.reloadPalette(PaletteManager.java:137)
at org.eclipse.wb.internal.core.editor.palette.DesignerPalette.reloadPalette(DesignerPalette.java:171)
at org.eclipse.wb.internal.core.editor.palette.DesignerPalette.setInput(DesignerPalette.java:138)
at org.eclipse.wb.internal.core.editor.JavaDesignComposite.refresh(JavaDesignComposite.java:146)
at org.eclipse.wb.internal.core.editor.DesignPage.internal_refreshGEF(DesignPage.java:585)
at org.eclipse.wb.internal.core.editor.DesignPage.access$9(DesignPage.java:522)
at org.eclipse.wb.internal.core.editor.DesignPage$8$1.run(DesignPage.java:449)
at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:233)
at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:144)
at org.eclipse.swt.widgets.Display.syncExec(Display.java:5439)
at org.eclipse.wb.internal.core.editor.DesignPage$8.run(DesignPage.java:446)
at org.eclipse.jface.operation.ModalContext.runInCurrentThread(ModalContext.java:437)
at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:353)
at org.eclipse.jface.dialogs.ProgressMonitorDialog.run(ProgressMonitorDialog.java:483)
at org.eclipse.wb.internal.core.editor.DesignPage.internal_refreshGEF_withProgress(DesignPage.java:465)
at org.eclipse.wb.internal.core.editor.DesignPage.internal_refreshGEF(DesignPage.java:415)
at org.eclipse.wb.internal.core.editor.UndoManager.refreshDesignerEditor(UndoManager.java:381)
at org.eclipse.wb.internal.core.editor.UndoManager.activate(UndoManager.java:90)
at org.eclipse.wb.internal.core.editor.DesignPage.handleActiveState_True(DesignPage.java:263)
at org.eclipse.wb.internal.core.editor.DesignPage.handleActiveState(DesignPage.java:241)
at org.eclipse.wb.internal.core.editor.multi.DefaultMultiMode.showPage(DefaultMultiMode.java:125)
at org.eclipse.wb.internal.core.editor.multi.DefaultMultiMode$1.widgetSelected(DefaultMultiMode.java:63)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:249)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:86)
at org.eclipse.swt.widgets.Display.sendEvent(Display.java:5252)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1348)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1374)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1357)
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:1142)
at org.eclipse.swt.custom.CTabFolder.setSelection(CTabFolder.java:3187)
at org.eclipse.swt.custom.CTabFolder.onMouse(CTabFolder.java:1870)
at org.eclipse.swt.custom.CTabFolder.lambda$0(CTabFolder.java:328)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:86)
at org.eclipse.swt.widgets.Display.sendEvent(Display.java:5252)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1348)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4522)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:4107)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$5.run(PartRenderingEngine.java:1155)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1044)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:153)
at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:680)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:594)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:148)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:151)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:653)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:590)
at org.eclipse.equinox.launcher.Main.run(Main.java:1499)
at org.eclipse.equinox.launcher.Main.main(Main.java:1472)

最佳答案

它解决了问题(以及其他问题,例如偶尔严重抖动的上下文菜单),只需像这样启动 eclipse 并使用 GTK2 而不是 GTK3:SWT_GTK3=0 ./eclipse

编辑:它似乎也可以这样工作:https://askubuntu.com/a/838703我用上面的方法丢失了我的菜单图标。链接方法没有这个缺陷。

关于java - 如何解决 "No more handles exception", Eclipse Oxygen, Windowbuilder Pro,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46341108/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com