且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何开发可以被所有其他应用程序所使用的Andr​​oid应用程序?

更新时间:2022-12-21 18:52:10

这取决于你真正想做的事,和其他应用程序是否不支持它。

It depends on what you actually want to do, and whether or not the other apps support it.

您更改字体全系统的例子是不可能的。任何应用程序可以定义哪些字体使用,并且你不能覆盖。强制应用程序使用不同的字体可能会降低该应用的用户体验,让我pretty高兴与此限制。

Your example of changing the fonts system-wide is not possible. Any application can define what fonts to use, and you cannot override that. Forcing an application to use a different font could degrade that app's user experience, so I am pretty happy with this limitation.

这听起来像你希望能够覆盖或控制其他应用程序(无论是他们的行为或他们的UI)。一般地,这是不可能的,除非其他应用程序的开发是为了明确地允许本

It sounds like you want to be able to override or control other applications (either their behavior or their UI). In general this is not possible unless the other application was developed to explicitly allow this.

但是,您可以连接到在其他方面的应用。举几个例子:

You can however hook into apps in other ways. A few examples:


  • 您的应用程序可以使用 的AccountManager 以及相关的类提供了全系统的帐户,其他应用程序可以使用。

  • 您的应用程序可以允许其他应用程序启动意图与你的应用程序进行通信

  • 您的应用程序可以注册意图过滤器处理某些行动,例如用户试图打开一个特定的文件类型,打开一个URL,或发送短信。

  • 应用程序,如 DashClock 允许其他开发人员创建插件应用程序提供新的功能

  • Your application can use the AccountManager and associated classes to provide a system-wide account that other applications can use.
  • Your application can allow other applications to launch Intents to communicate with your application
  • Your application can register intent filters to handle certain actions such as the user trying to open a specific file type, opening a URL, or sending a text message.
  • Apps such as DashClock allow other developers to create plugin applications to provide new functionality