小编Kou*_*Deb的帖子

使用 Pyinstaller Spec 向 EXE 文件添加图标时没有错误,仍然没有显示图标

我是 pyinstaller 的新手。当我编译我的 exe 文件时,我没有出错。 编译时输出

我已将徽标路径添加到规范文件。

exe = EXE(pyz,
      a.scripts,
      a.binaries,
      Tree('exp','exp'),
      a.zipfiles,
      a.datas,
      name='Screen2text',
      debug=False,
      bootloader_ignore_signals=False,
      strip=False,
      upx=True,
      upx_exclude=[],
      runtime_tmpdir=None,
      console=False,
      icon=r'D:\backup\logo.ico')
Run Code Online (Sandbox Code Playgroud)

但是编译后,我在我的exe文件上看不到那个标志。我的标志文件的大小是423KB。我错过了什么吗?

python exe publishing pyinstaller

3
推荐指数
1
解决办法
398
查看次数

在 Flutter 中使用 awesome_notifications 显示通知的问题

我是 flutter 的新手。我已经开始创建一个提醒应用程序。我正在尝试在 android 警报回调上调用推送通知。我正在使用 awesome_notifications。回电时,我正在调用 _ringAlarm()。我已将其粘贴在下面。它说 D/NotificationSender(5192): 通知已创建但在屏幕上显示。

运行时抛出此异常。

W/System.err(5192):java.lang.IllegalArgumentException:无效通知(没有有效的小图标):通知(channel=basic_channel快捷方式=null contentView=null vibrate=null sound=null tick defaults=0x0 flags=0x11 color= 0xff9d50dd vis=UNKNOWN(2))

Future _ringAlarm() async {

  AwesomeNotifications().initialize(
    'resource://drawable/logo.png',
    [
        NotificationChannel(
            channelKey: 'basic_channel',
            channelName: 'Basic notifications',
            channelDescription: 'Notification channel for basic tests',
            defaultColor: Color(0xFF9D50DD),
            ledColor: Colors.white
        )
    ]
  );

  AwesomeNotifications().isNotificationAllowed().then((isAllowed) {
    if (!isAllowed) {
      AwesomeNotifications().requestPermissionToSendNotifications();
    }
  });

  AwesomeNotifications().createNotification(
    content: NotificationContent(
        id: 10,
        channelKey: 'basic_channel',
        title: 'Simple Notification',
        body: 'Simple body'
    )
  );

}
Run Code Online (Sandbox Code Playgroud)

android dart flutter flutter-layout

3
推荐指数
1
解决办法
1360
查看次数

标签 统计

android ×1

dart ×1

exe ×1

flutter ×1

flutter-layout ×1

publishing ×1

pyinstaller ×1

python ×1