[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

WO2022002213A1 - Translation result display method and apparatus, and electronic device - Google Patents

Translation result display method and apparatus, and electronic device Download PDF

Info

Publication number
WO2022002213A1
WO2022002213A1 PCT/CN2021/104070 CN2021104070W WO2022002213A1 WO 2022002213 A1 WO2022002213 A1 WO 2022002213A1 CN 2021104070 W CN2021104070 W CN 2021104070W WO 2022002213 A1 WO2022002213 A1 WO 2022002213A1
Authority
WO
WIPO (PCT)
Prior art keywords
application
electronic device
display
translation
user
Prior art date
Application number
PCT/CN2021/104070
Other languages
French (fr)
Chinese (zh)
Inventor
王波
文平
陈光军
朱培
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2022002213A1 publication Critical patent/WO2022002213A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/40Processing or translation of natural language
    • G06F40/58Use of machine translation, e.g. for multi-lingual retrieval, for server-side translation for client devices or for real-time translation

Definitions

  • the present application belongs to the field of computer technology, and in particular relates to a translation result display method, device and electronic device.
  • the embodiments of the present application provide a translation result display method, device and electronic device, which can solve the technical problems of complicated user operations and low efficiency in the translation process of the related art.
  • an embodiment of the present application provides a method for displaying translation results, including:
  • the display interface of the first application and the display interface of the second application are displayed in a split screen; or, the display interface of the second application is superimposed and displayed on the On the display interface of the first application, the second application is a translation application;
  • the translation result is displayed on the display interface of the second application.
  • the translation result of the content currently displayed by the first application can be displayed in the second application through a simple user operation, which reduces the interaction cost and improves the efficiency.
  • the display interfaces of the first application and the second application are displayed at the same time, that is, the display screen simultaneously displays the content and the translation result, which increases the amount of information displayed on the display screen and improves the efficiency of multi-task interaction.
  • the display interface of the first application and the display interface of the second application are displayed in a split screen in response to the first operation input by the user in the first application;
  • the display interface of the second application is superimposed and displayed on the display interface of the first application, including:
  • a system pop-up box In response to the first operation input by the user in the first application, a system pop-up box is triggered, and the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the display interface of the first application and the display interface of the second application are displayed in a split screen; or, the display interface of the second application is superimposed and displayed on the on the display interface of the first application.
  • the triggering of the system pop-up frame is added, which prevents the display interface of the second application from being displayed due to user misoperation, and improves the anti-mistouch performance of the solution.
  • the method before translating the display content in the first application into a target language and obtaining a translation result, the method further includes:
  • the source language and/or the target language can be input by the user, which can adapt to the user's needs and improve the diversity of solutions.
  • the method further includes:
  • the display interface of the first application or the display interface of the second application is switched to a floating window.
  • the method when the display interface of the second application is superimposed and displayed on the display interface of the first application, the method further includes:
  • the display interface of the first application and the display interface of the second application are switched to split-screen display.
  • switching between split-screen display and superimposed display can be achieved through a simple user operation, and the display mode of the display screen can be quickly switched according to user requirements, which improves interaction efficiency.
  • the method further includes:
  • the second application automatically updates the translation result synchronously according to the display content updated by the first application, which does not require user operation, thereby improving translation efficiency.
  • the method further includes:
  • a translation result of the content currently displayed on the display interface of the first application is displayed on the display interface of the second application.
  • the second application synchronously updates the translation result according to the display content updated by the first application in response to the user operation, so that the embodiment of the present application is applicable to more scenarios.
  • the method further includes:
  • the translation result is updated synchronously, and the user does not need to input a user operation in the second application, Improved translation efficiency.
  • the first application is a non-translation application.
  • an embodiment of the present application further provides a translation result display device, including:
  • a first display module configured to display the display interface of the first application and the display interface of the second application in a split screen in response to a first operation input by the user in the first application; or, display the second application
  • the display interface is superimposed and displayed on the display interface of the first application, and the second application is a translation application;
  • a translation module for translating the current display content in the first application into a target language to obtain a translation result
  • the second display module is configured to display the translation result on the display interface of the second application.
  • the first display module is specifically used for:
  • a system pop-up box In response to the first operation input by the user in the first application, a system pop-up box is triggered, and the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the display interface of the first application and the display interface of the second application are displayed in a split screen; or, the display interface of the second application is superimposed and displayed on the on the display interface of the first application.
  • the method further includes a language acquisition module, configured to:
  • the apparatus further includes a first switching module, the first switching module Modules are used to:
  • the display interface of the first application or the display interface of the second application is switched to a floating window.
  • the apparatus when the display interface of the second application is superimposed and displayed on the display interface of the first application, the apparatus further includes a second switching module, the second Toggle modules are used to:
  • the display interface of the first application and the display interface of the second application are switched to split-screen display.
  • the device further includes a first translation update module, where the first translation update module is configured to:
  • the apparatus further includes a second translation update module, which is used for:
  • a translation result of the content currently displayed on the display interface of the first application is displayed on the display interface of the second application.
  • the device further includes a third translation update module, the third translation update module is used for:
  • the embodiments of the present application provide a method for displaying translation results, including:
  • the first electronic device in response to the first operation input by the user in the first application, translates the currently displayed content in the first application into the target language, and obtains a translation result;
  • the first electronic device sends the translation result to a second electronic device communicatively connected to the first electronic device for display.
  • the translation result of the content currently displayed by the first application on the first electronic device can be displayed on the second electronic device through a simple user operation.
  • the interaction cost is reduced and the efficiency is improved;
  • the display capabilities of different devices are greatly used, and the reading efficiency is improved.
  • the first electronic device in response to a first operation input by the user in the first application, translates the content currently displayed in the first application into a target language, and obtains a translation result, including :
  • the first electronic device displays a device list in response to a first operation input by the user in the first application
  • the first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
  • the first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
  • the first electronic device in response to a first operation input by the user in the first application, translates the content currently displayed in the first application into a target language, and obtains a translation result, including :
  • the first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
  • the first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
  • the first electronic device in response to a first operation input by the user in the first application, translates the content currently displayed in the first application into a target language, and obtains a translation result, including :
  • the first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list
  • the first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
  • the first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
  • the method further includes:
  • the first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
  • the first electronic device instructs the second electronic device to update the translation result synchronously according to the display content updated by the first application, without requiring the user to input a specific operation, thereby improving translation efficiency.
  • the method further includes:
  • the first electronic device receives a refresh translation operation input by the user
  • the first electronic device in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
  • the method further includes:
  • the first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
  • the first electronic device in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
  • the first electronic device or the second electronic device implements the first electronic device to instruct the second electronic device to update the translation result synchronously according to a specific operation input by the user, thereby improving translation efficiency.
  • the method further includes:
  • the first electronic device receives a second operation input by the user in the first application
  • the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
  • the first electronic device in response to the received user operation, if it is determined that the display content is updated, the first electronic device instructs the second electronic device to update the translation result synchronously, thereby improving translation efficiency.
  • an embodiment of the present application further provides a translation result display device, including:
  • a translation module used for the first electronic device to translate the currently displayed content in the first application into a target language in response to a first operation input by the user in the first application, and obtain a translation result
  • a sending module is used for the first electronic device to send the translation result to a second electronic device communicatively connected to the first electronic device for display.
  • the translation module is specifically used for:
  • the first electronic device displays a device list in response to a first operation input by the user in the first application
  • the first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
  • the first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
  • the translation module is specifically used for:
  • the first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
  • the first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
  • the translation module is specifically used for:
  • the first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list
  • the first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
  • the first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
  • the device further includes a first translation update module, where the first translation update module is configured to:
  • the first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
  • the device further includes a second translation update module
  • the second translation update module is used for:
  • the first electronic device receives a refresh translation operation input by the user
  • the first electronic device in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
  • the second translation update module is used for:
  • the first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
  • the first electronic device in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
  • the device further includes a third translation update module, which is used for:
  • the first electronic device receives a second operation input by the user in the first application
  • the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
  • the embodiments of the present application provide a method for displaying translation results, including:
  • the first electronic device in response to a first operation input by the user in the first application, acquires the currently displayed content in the first application;
  • the first electronic device sends the currently displayed content to a second electronic device that is communicatively connected to the first electronic device, and instructs the second electronic device to translate the displayed content into a target language before displaying it.
  • the translation result of the content currently displayed by the first application on the first electronic device can be displayed on the second electronic device through a simple user operation.
  • the interaction cost is reduced and the efficiency is improved;
  • the display capabilities of different devices are greatly used, and the reading efficiency is improved.
  • the first electronic device in response to a first operation input by a user in the first application, acquires the current display content in the first application, including:
  • the first electronic device displays a device list in response to a first operation input by the user in the first application
  • the first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
  • the first electronic device acquires the currently displayed content in the first application.
  • the first electronic device in response to a first operation input by the user in the first application, acquires the currently displayed content in the first application, including:
  • the first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
  • the first electronic device acquires the currently displayed content in the first application.
  • the first electronic device in response to a first operation input by the user in the first application, acquires the currently displayed content in the first application, including:
  • the first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list
  • the first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
  • the first electronic device acquires the currently displayed content in the first application.
  • the method further includes:
  • the first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
  • the first electronic device instructs the second electronic device to update the translation result synchronously according to the display content updated by the first application, without requiring the user to input a specific operation, thereby improving translation efficiency.
  • the method further includes:
  • the first electronic device receives a refresh translation operation input by the user
  • the first electronic device in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
  • the method further includes:
  • the first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
  • the first electronic device in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
  • the first electronic device or the second electronic device realizes that the first electronic device instructs the second electronic device to update the translation result synchronously according to a specific operation input by the user, thereby improving translation efficiency.
  • the method further includes:
  • the first electronic device receives a second operation input by the user in the first application
  • the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
  • the first electronic device in response to the received user operation, if it is determined that the displayed content is updated, the first electronic device instructs the second electronic device to update the translation result synchronously, thereby improving translation efficiency.
  • an embodiment of the present application further provides a translation result display device, including:
  • an obtaining module used for the first electronic device to obtain the currently displayed content in the first application in response to the first operation input by the user in the first application;
  • a sending module used for the first electronic device to send the currently displayed content to a second electronic device that is communicatively connected to the first electronic device, and instruct the second electronic device to translate the displayed content into a target displayed after the language.
  • the acquisition module is specifically used for:
  • the first electronic device displays a device list in response to a first operation input by the user in the first application
  • the first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
  • the first electronic device acquires the currently displayed content in the first application.
  • the acquisition module is specifically used for:
  • the first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
  • the first electronic device acquires the currently displayed content in the first application.
  • the acquisition module is specifically used for:
  • the first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, and the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
  • the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list
  • the first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
  • the first electronic device acquires the currently displayed content in the first application.
  • the device further includes a first translation update module, where the first translation update module is configured to:
  • the first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
  • the apparatus further includes a second translation update module, which is used for:
  • the first electronic device receives a refresh translation operation input by the user
  • the first electronic device in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
  • the second translation update module is used for:
  • the first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
  • the first electronic device in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
  • the device further includes a third translation update module, which is used for:
  • the first electronic device receives a second operation input by the user in the first application
  • the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
  • an embodiment of the present application provides an electronic device, including a display screen, a memory, a processor, and a computer program stored in the memory and executable on the processor, the processor executing the In the case of a computer program, the electronic device is made to implement the method described in any one of the first aspect and the possible implementation manner of the first aspect, or implement the method described in any one of the third aspect and the possible implementation manner of the third aspect The method, or, implement the method according to any one of the fifth aspect and the possible implementation manner of the fifth aspect.
  • an embodiment of the present application provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the first aspect and the first aspect are possible Implement the method described in any one of the implementation manners, or, implement the method described in any one of the third aspect and the possible implementation manner of the third aspect, or implement any of the possible implementation manners of the fifth aspect and the fifth aspect. a described method.
  • an embodiment of the present application provides a computer program product that, when the computer program product runs on an electronic device, enables the electronic device to execute the method described in any one of the first aspect and the possible implementations of the first aspect , or, perform the method described in any one of the third aspect and possible implementation manners of the third aspect, or perform the method described in any one of the foregoing fifth aspect and possible implementation manners of the fifth aspect.
  • FIG. 1 is a schematic diagram of the hardware structure of a mobile phone to which a translation result display method provided by an embodiment of the present application is applicable;
  • 2A is a schematic diagram of a software structure of a mobile phone to which the translation result display method provided by an embodiment of the present application is applicable;
  • 2B is a schematic diagram of a software structure of a mobile phone to which the translation result display method provided by an embodiment of the present application is applicable;
  • 3A is a schematic flowchart of a translation result display method provided by an embodiment of the present application.
  • 3B is a schematic diagram of triggering a system pop-up frame on a display interface of a reading APP provided by an embodiment of the present application;
  • 3C is a schematic diagram of split-screen display of a reading APP and a translation APP provided by an embodiment of the present application;
  • 3D is an example diagram of split-screen display of a reading APP and a translation APP provided by another embodiment of the present application;
  • 3E is an example diagram of inputting a source language and a target language on a display interface of a translation APP provided by an embodiment of the present application;
  • 3F is a schematic diagram of a reading APP and a translation APP provided by an embodiment of the present application to display reading content and translation results on a split screen;
  • 3G is a schematic diagram of a reading APP and a translation APP provided by another embodiment of the present application to display reading content and translation results in split screens;
  • FIG. 4A is a schematic flowchart of a translation APP displaying translation results provided by an embodiment of the present application
  • 4B is a schematic diagram of obtaining a screenshot of a reading APP display provided by an embodiment of the present application.
  • 5A is a schematic diagram of a user confirming entry into a split-screen translation interface provided by an embodiment of the present application
  • 5B is a schematic diagram of a translation APP provided by an embodiment of the present application being superimposed and displayed on a reading APP;
  • 5C is a schematic diagram of switching from a floating window to a split-screen display provided by an embodiment of the present application.
  • 5D is a schematic diagram of switching from a floating window to a split-screen display provided by another embodiment of the present application.
  • 5E is a schematic diagram of switching from a split-screen display to a floating window provided by an embodiment of the present application.
  • 5F is a schematic diagram of switching from split-screen display to a floating window provided by another embodiment of the present application.
  • 5G is a schematic diagram of switching from split-screen display to a floating window provided by another embodiment of the present application.
  • 5H is a schematic diagram of switching from split-screen display to a floating window provided by another embodiment of the present application.
  • 6A is a schematic flowchart of a translation result display method provided by another embodiment of the present application.
  • 6B is a schematic diagram of the translation result corresponding to the updated display content of the reading APP displayed automatically and synchronously by the translation APP provided by an embodiment of the present application;
  • FIG. 7A is a schematic flowchart of a translation result display method provided by another embodiment of the present application.
  • FIG. 7B is a schematic diagram of a translation result corresponding to the updated display content of the reading APP being synchronously displayed by the translation APP through manual operation by the user according to an embodiment of the present application;
  • FIG. 8 is a schematic flowchart of a translation result display method provided by another embodiment of the present application.
  • 9A is a schematic flowchart of a translation result display method provided by another embodiment of the present application.
  • FIG. 9B is a schematic process diagram of a translation result display method provided by another embodiment of the present application.
  • the term “comprising” indicates the presence of the described feature, integer, step, operation, element and/or component, but does not exclude one or more other features, integers , step, operation, element, component and/or the presence or addition of a collection thereof.
  • the term “if” may be interpreted, depending on the context, as “when” or “once” or “in response to determining” or “in response to detecting ".
  • references in this specification to "one embodiment” or “some embodiments” and the like mean that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application.
  • appearances of the phrases “in some embodiments,” “in other embodiments,” “in other embodiments,” etc. in various places in this specification are not necessarily all referring to the same embodiment, but rather is meant to mean “one or more but not all embodiments” unless specifically emphasized otherwise.
  • the terms “including”, “including”, “having” and their variants mean “including but not limited to” unless specifically emphasized otherwise.
  • the present application provides a method for displaying translation results.
  • the translation result display method provided by the embodiment of the present application, on the one hand, the translation result can be displayed through a simple user operation, which simplifies the user operation and improves the efficiency; Simultaneous display, displaying more information on one screen, improves the efficiency of multi-task interaction.
  • the translation result display method provided by the embodiment of the present application is suitable for the situation that a user needs to translate when reading through an electronic device.
  • the translation result display method is applied to an electronic device, and can be executed by a translation result display device configured in the electronic device.
  • the translation result display device may be implemented by software, hardware, or a combination of software and hardware of an electronic device.
  • the translation result display method provided by the embodiments of the present application can be applied to mobile phones, tablet computers, wearable devices, in-vehicle devices (or vehicle machines), augmented reality (AR)/virtual reality (VR) devices, Electronic devices such as notebook computers, ultra-mobile personal computers (UMPCs), netbooks, personal digital assistants (PDAs), smart screens, TVs, and smart speakers. Type does not impose any restrictions.
  • FIG. 1 shows a schematic structural diagram of an electronic device 100 .
  • the electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charge management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2 , mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, sensor module 180, buttons 190, motor 191, indicator 192, camera 193, display screen 194, and Subscriber identification module (subscriber identification module, SIM) card interface 195 and so on.
  • SIM Subscriber identification module
  • the sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, and ambient light. Sensor 180L, bone conduction sensor 180M, etc.
  • the structures illustrated in the embodiments of the present invention do not constitute a specific limitation on the electronic device 100 .
  • the electronic device 100 may include more or less components than shown, or combine some components, or separate some components, or arrange different components.
  • the illustrated components may be implemented in hardware, software, or a combination of software and hardware.
  • the processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), controller, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (neural-network processing unit, NPU), etc. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
  • application processor application processor, AP
  • modem processor graphics processor
  • ISP image signal processor
  • controller video codec
  • digital signal processor digital signal processor
  • baseband processor baseband processor
  • neural-network processing unit neural-network processing unit
  • the controller can generate an operation control signal according to the instruction operation code and timing signal, and complete the control of fetching and executing instructions.
  • a memory may also be provided in the processor 110 for storing instructions and data.
  • the memory in processor 110 is cache memory. This memory may hold instructions or data that have just been used or recycled by the processor 110 . If the processor 110 needs to use the instruction or data again, it can be called directly from the memory. Repeated accesses are avoided and the latency of the processor 110 is reduced, thereby increasing the efficiency of the system.
  • the processor 110 may include one or more interfaces.
  • the interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous transceiver (universal asynchronous transmitter) receiver/transmitter, UART) interface, mobile industry processor interface (MIPI), general-purpose input/output (GPIO) interface, subscriber identity module (SIM) interface, and / or universal serial bus (universal serial bus, USB) interface, etc.
  • I2C integrated circuit
  • I2S integrated circuit built-in audio
  • PCM pulse code modulation
  • PCM pulse code modulation
  • UART universal asynchronous transceiver
  • MIPI mobile industry processor interface
  • GPIO general-purpose input/output
  • SIM subscriber identity module
  • USB universal serial bus
  • the I2C interface is a bidirectional synchronous serial bus that includes a serial data line (SDA) and a serial clock line (SCL).
  • the processor 110 may contain multiple sets of I2C buses.
  • the processor 110 can be respectively coupled to the touch sensor 180K, the charger, the flash, the camera 193 and the like through different I2C bus interfaces.
  • the processor 110 may couple the touch sensor 180K through the I2C interface, so that the processor 110 and the touch sensor 180K communicate with each other through the I2C bus interface, so as to realize the touch function of the electronic device 100 .
  • the I2S interface can be used for audio communication.
  • the processor 110 may contain multiple sets of I2S buses.
  • the processor 110 may be coupled with the audio module 170 through an I2S bus to implement communication between the processor 110 and the audio module 170 .
  • the audio module 170 can transmit audio signals to the wireless communication module 160 through the I2S interface, so as to realize the function of answering calls through a Bluetooth headset.
  • the PCM interface can also be used for audio communications, sampling, quantizing and encoding analog signals.
  • the audio module 170 and the wireless communication module 160 may be coupled through a PCM bus interface.
  • the audio module 170 can also transmit audio signals to the wireless communication module 160 through the PCM interface, so as to realize the function of answering calls through the Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.
  • the UART interface is a universal serial data bus used for asynchronous communication.
  • the bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication.
  • a UART interface is typically used to connect the processor 110 with the wireless communication module 160 .
  • the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function.
  • the audio module 170 can transmit audio signals to the wireless communication module 160 through the UART interface, so as to realize the function of playing music through the Bluetooth headset.
  • the MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193 .
  • MIPI interfaces include camera serial interface (CSI), display serial interface (DSI), etc.
  • the processor 110 communicates with the camera 193 through a CSI interface, so as to realize the photographing function of the electronic device 100 .
  • the processor 110 communicates with the display screen 194 through the DSI interface to implement the display function of the electronic device 100 .
  • the GPIO interface can be configured by software.
  • the GPIO interface can be configured as a control signal or as a data signal.
  • the GPIO interface may be used to connect the processor 110 with the camera 193, the display screen 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like.
  • the GPIO interface can also be configured as I2C interface, I2S interface, UART interface, MIPI interface, etc.
  • the USB interface 130 is an interface that conforms to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, and the like.
  • the USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transmit data between the electronic device 100 and peripheral devices. It can also be used to connect headphones to play audio through the headphones.
  • the interface can also be used to connect other electronic devices, such as AR devices.
  • the interface connection relationship between the modules illustrated in the embodiment of the present invention is only a schematic illustration, and does not constitute a structural limitation of the electronic device 100 .
  • the electronic device 100 may also adopt different interface connection manners in the foregoing embodiments, or a combination of multiple interface connection manners.
  • the charging management module 140 is used to receive charging input from the charger.
  • the charger may be a wireless charger or a wired charger.
  • the charging management module 140 may receive charging input from the wired charger through the USB interface 130 .
  • the charging management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100 . While the charging management module 140 charges the battery 142 , it can also supply power to the electronic device through the power management module 141 .
  • the power management module 141 is used for connecting the battery 142 , the charging management module 140 and the processor 110 .
  • the power management module 141 receives the input from the battery 142 and/or the charging management module 140 and supplies power to the processor 110 , the internal memory 121 , the display screen 194 , the camera 193 , and the wireless communication module 160 .
  • the power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle times, battery health status (leakage, impedance).
  • the power management module 141 may also be provided in the processor 110 .
  • the power management module 141 and the charging management module 140 may also be provided in the same device.
  • the wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modulation and demodulation processor, the baseband processor, and the like.
  • Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals.
  • Each antenna in electronic device 100 may be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization.
  • the antenna 1 can be multiplexed as a diversity antenna of the wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
  • the mobile communication module 150 may provide wireless communication solutions including 2G/3G/4G/5G etc. applied on the electronic device 100 .
  • the mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA) and the like.
  • the mobile communication module 150 can receive electromagnetic waves from the antenna 1, filter and amplify the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation.
  • the mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and then turn it into an electromagnetic wave for radiation through the antenna 1 .
  • at least part of the functional modules of the mobile communication module 150 may be provided in the processor 110 .
  • at least part of the functional modules of the mobile communication module 150 may be provided in the same device as at least part of the modules of the processor 110 .
  • the modem processor may include a modulator and a demodulator.
  • the modulator is used to modulate the low frequency baseband signal to be sent into a medium and high frequency signal.
  • the demodulator is used to demodulate the received electromagnetic wave signal into a low frequency baseband signal.
  • the demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing.
  • the low frequency baseband signal is processed by the baseband processor and passed to the application processor.
  • the application processor outputs sound signals through audio devices (not limited to the speaker 170A, the receiver 170B, etc.), or displays images or videos through the display screen 194 .
  • the modem processor may be a stand-alone device.
  • the modem processor may be independent of the processor 110, and may be provided in the same device as the mobile communication module 150 or other functional modules.
  • the wireless communication module 160 can provide applications on the electronic device 100 including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellites System (global navigation satellite system, GNSS), frequency modulation (frequency modulation, FM), near field communication technology (near field communication, NFC), infrared technology (infrared, IR) and other wireless communication solutions.
  • WLAN wireless local area networks
  • BT wireless fidelity
  • GNSS global navigation satellites System
  • frequency modulation frequency modulation, FM
  • NFC near field communication technology
  • IR infrared technology
  • the wireless communication module 160 may be one or more devices integrating at least one communication processing module.
  • the wireless communication module 160 receives electromagnetic waves via the antenna 2 , frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 110 .
  • the wireless communication module 160 can also receive the signal to be sent from the processor 110 , perform frequency modulation on it, amplify it, and convert it into electromagnetic waves for radiation through
  • the antenna 1 of the electronic device 100 is coupled with the mobile communication module 150, and the antenna 2 is coupled with the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology.
  • the wireless communication technologies may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), broadband Code Division Multiple Access (WCDMA), Time Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC , FM, and/or IR technology, etc.
  • the GNSS may include a global positioning system (global positioning system, GPS), a global navigation satellite system (GLONASS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (quasi -zenith satellite system, QZSS) and/or satellite based augmentation systems (SBAS).
  • GPS global positioning system
  • GLONASS global navigation satellite system
  • BDS Beidou navigation satellite system
  • QZSS quasi-zenith satellite system
  • SBAS satellite based augmentation systems
  • the electronic device 100 implements a display function through a GPU, a display screen 194, an application processor, and the like.
  • the GPU is a microprocessor for image processing, and is connected to the display screen 194 and the application processor.
  • the GPU is used to perform mathematical and geometric calculations for graphics rendering.
  • Processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.
  • Display screen 194 is used to display images, videos, and the like.
  • Display screen 194 includes a display panel.
  • the display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (active-matrix organic light).
  • LED diode AMOLED
  • flexible light-emitting diode flexible light-emitting diode (flex light-emitting diode, FLED), Miniled, MicroLed, Micro-oLed, quantum dot light-emitting diode (quantum dot light emitting diodes, QLED) and so on.
  • the electronic device 100 may include one or N display screens 194 , where N is a positive integer greater than one.
  • the electronic device 100 may implement a shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
  • the ISP is used to process the data fed back by the camera 193 .
  • the shutter is opened, the light is transmitted to the camera photosensitive element through the lens, the light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye.
  • ISP can also perform algorithm optimization on image noise, brightness, and skin tone.
  • ISP can also optimize the exposure, color temperature and other parameters of the shooting scene.
  • the ISP may be provided in the camera 193 .
  • Camera 193 is used to capture still images or video.
  • the object is projected through the lens to generate an optical image onto the photosensitive element.
  • the photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor.
  • CMOS complementary metal-oxide-semiconductor
  • the photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal.
  • the ISP outputs the digital image signal to the DSP for processing.
  • DSP converts digital image signals into standard RGB, YUV and other formats of image signals.
  • the electronic device 100 may include 1 or N cameras 193 , where N is a positive integer greater than 1.
  • a digital signal processor is used to process digital signals, in addition to processing digital image signals, it can also process other digital signals. For example, when the electronic device 100 selects a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy and so on.
  • Video codecs are used to compress or decompress digital video.
  • the electronic device 100 may support one or more video codecs.
  • the electronic device 100 can play or record videos of various encoding formats, such as: Moving Picture Experts Group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4 and so on.
  • MPEG Moving Picture Experts Group
  • MPEG2 moving picture experts group
  • MPEG3 MPEG4
  • MPEG4 Moving Picture Experts Group
  • the NPU is a neural-network (NN) computing processor.
  • NN neural-network
  • Applications such as intelligent cognition of the electronic device 100 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, and the like.
  • the external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100 .
  • the external memory card communicates with the processor 110 through the external memory interface 120 to realize the data storage function. For example to save files like music, video etc in external memory card.
  • Internal memory 121 may be used to store computer executable program code, which includes instructions.
  • the internal memory 121 may include a storage program area and a storage data area.
  • the storage program area can store an operating system, an application program required for at least one function (such as a sound playback function, an image playback function, etc.), and the like.
  • the storage data area may store data (such as audio data, phone book, etc.) created during the use of the electronic device 100 and the like.
  • the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), and the like.
  • the processor 110 executes various functional applications and data processing of the electronic device 100 by executing instructions stored in the internal memory 121 and/or instructions stored in a memory provided in the processor.
  • the electronic device 100 may implement audio functions through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, an application processor, and the like. Such as music playback, recording, etc.
  • the audio module 170 is used for converting digital audio information into analog audio signal output, and also for converting analog audio input into digital audio signal. Audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be provided in the processor 110 , or some functional modules of the audio module 170 may be provided in the processor 110 .
  • Speaker 170A also referred to as a "speaker" is used to convert audio electrical signals into sound signals.
  • the electronic device 100 can listen to music through the speaker 170A, or listen to a hands-free call.
  • the receiver 170B also referred to as "earpiece" is used to convert audio electrical signals into sound signals.
  • the voice can be answered by placing the receiver 170B close to the human ear.
  • the microphone 170C also called “microphone” or “microphone” is used to convert sound signals into electrical signals.
  • the user can make a sound by approaching the microphone 170C through a human mouth, and input the sound signal into the microphone 170C.
  • the electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C, which can implement a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and implement directional recording functions.
  • the earphone jack 170D is used to connect wired earphones.
  • the earphone interface 170D can be the USB interface 130, or can be a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.
  • OMTP open mobile terminal platform
  • CTIA cellular telecommunications industry association of the USA
  • the pressure sensor 180A is used to sense pressure signals, and can convert the pressure signals into electrical signals.
  • pressure sensor 180A may be provided on display screen 194.
  • the capacitive pressure sensor may be comprised of at least two parallel plates of conductive material. When a force is applied to the pressure sensor 180A, the capacitance between the electrodes changes.
  • the electronic device 100 determines the intensity of the pressure according to the change in capacitance.
  • the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A.
  • the electronic device 100 may also calculate the touched position according to the detection signal of the pressure sensor 180A.
  • touch operations acting on the same touch position but with different touch operation intensities may correspond to different operation instructions. For example, when a touch operation whose intensity is less than the first pressure threshold acts on the short message application icon, the instruction for viewing the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, the instruction to create a new short message is executed.
  • the gyro sensor 180B may be used to determine the motion attitude of the electronic device 100 .
  • the angular velocity of electronic device 100 about three axes ie, x, y, and z axes
  • the gyro sensor 180B can be used for image stabilization.
  • the gyro sensor 180B detects the shaking angle of the electronic device 100, calculates the distance that the lens module needs to compensate according to the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse motion to achieve anti-shake.
  • the gyro sensor 180B can also be used for navigation and somatosensory game scenarios.
  • the air pressure sensor 180C is used to measure air pressure.
  • the electronic device 100 calculates the altitude through the air pressure value measured by the air pressure sensor 180C to assist in positioning and navigation.
  • the magnetic sensor 180D includes a Hall sensor.
  • the electronic device 100 can detect the opening and closing of the flip holster using the magnetic sensor 180D.
  • the electronic device 100 can detect the opening and closing of the flip according to the magnetic sensor 180D. Further, according to the detected opening and closing state of the leather case or the opening and closing state of the flip cover, characteristics such as automatic unlocking of the flip cover are set.
  • the acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in various directions (generally three axes).
  • the magnitude and direction of gravity can be detected when the electronic device 100 is stationary. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
  • the electronic device 100 can measure the distance through infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.
  • Proximity light sensor 180G may include, for example, light emitting diodes (LEDs) and light detectors, such as photodiodes.
  • the light emitting diodes may be infrared light emitting diodes.
  • the electronic device 100 emits infrared light to the outside through the light emitting diode.
  • Electronic device 100 uses photodiodes to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100 . When insufficient reflected light is detected, the electronic device 100 may determine that there is no object near the electronic device 100 .
  • the electronic device 100 can use the proximity light sensor 180G to detect that the user holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power.
  • Proximity light sensor 180G can also be used in holster mode, pocket mode automatically unlocks and locks the screen.
  • the ambient light sensor 180L is used to sense ambient light brightness.
  • the electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness.
  • the ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures.
  • the ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket, so as to prevent accidental touch.
  • the fingerprint sensor 180H is used to collect fingerprints.
  • the electronic device 100 can use the collected fingerprint characteristics to realize fingerprint unlocking, accessing application locks, taking pictures with fingerprints, answering incoming calls with fingerprints, and the like.
  • the temperature sensor 180J is used to detect the temperature.
  • the electronic device 100 uses the temperature detected by the temperature sensor 180J to execute a temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold value, the electronic device 100 reduces the performance of the processor located near the temperature sensor 180J in order to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to avoid abnormal shutdown of the electronic device 100 caused by the low temperature. In some other embodiments, when the temperature is lower than yet another threshold, the electronic device 100 performs a boost to the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.
  • Touch sensor 180K also called “touch device”.
  • the touch sensor 180K may be disposed on the display screen 194 , and the touch sensor 180K and the display screen 194 form a touch screen, also called a “touch screen”.
  • the touch sensor 180K is used to detect a touch operation on or near it.
  • the touch sensor can pass the detected touch operation to the application processor to determine the type of touch event.
  • Visual output related to touch operations may be provided through display screen 194 .
  • the touch sensor 180K may also be disposed on the surface of the electronic device 100 , which is different from the location where the display screen 194 is located.
  • the bone conduction sensor 180M can acquire vibration signals.
  • the bone conduction sensor 180M can acquire the vibration signal of the vibrating bone mass of the human voice.
  • the bone conduction sensor 180M can also contact the pulse of the human body and receive the blood pressure beating signal.
  • the bone conduction sensor 180M can also be disposed in the earphone, combined with the bone conduction earphone.
  • the audio module 170 can analyze the voice signal based on the vibration signal of the vocal vibration bone block obtained by the bone conduction sensor 180M, so as to realize the voice function.
  • the application processor can analyze the heart rate information based on the blood pressure beat signal obtained by the bone conduction sensor 180M, and realize the function of heart rate detection.
  • the keys 190 include a power-on key, a volume key, and the like. Keys 190 may be mechanical keys. It can also be a touch key.
  • the electronic device 100 may receive key inputs and generate key signal inputs related to user settings and function control of the electronic device 100 .
  • Motor 191 can generate vibrating cues.
  • the motor 191 can be used for vibrating alerts for incoming calls, and can also be used for touch vibration feedback.
  • touch operations acting on different applications can correspond to different vibration feedback effects.
  • the motor 191 can also correspond to different vibration feedback effects for touch operations on different areas of the display screen 194 .
  • Different application scenarios for example: time reminder, receiving information, alarm clock, games, etc.
  • the touch vibration feedback effect can also support customization.
  • the indicator 192 can be an indicator light, which can be used to indicate the charging state, the change of the power, and can also be used to indicate a message, a missed call, a notification, and the like.
  • the SIM card interface 195 is used to connect a SIM card.
  • the SIM card can be contacted and separated from the electronic device 100 by inserting into the SIM card interface 195 or pulling out from the SIM card interface 195 .
  • the electronic device 100 may support 1 or N SIM card interfaces, where N is a positive integer greater than 1.
  • the SIM card interface 195 can support Nano SIM card, Micro SIM card, SIM card and so on. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the plurality of cards may be the same or different.
  • the SIM card interface 195 can also be compatible with different types of SIM cards.
  • the SIM card interface 195 is also compatible with external memory cards.
  • the electronic device 100 interacts with the network through the SIM card to implement functions such as call and data communication.
  • the electronic device 100 employs an eSIM, ie: an embedded SIM card.
  • the eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100 .
  • the software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture.
  • the embodiment of the present invention takes an Android system with a layered architecture as an example to illustrate the software structure of the electronic device 100 as an example.
  • FIG. 2A is a block diagram of a software structure of an electronic device 100 to which the translation result display method provided by an embodiment of the present invention is applied.
  • the layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate with each other through software interfaces.
  • the Android system is divided into four layers, which are, from top to bottom, an application layer, an application framework layer, an Android runtime (Android runtime) and a system library, and a kernel layer.
  • the application layer can include a series of application packages.
  • the application package may include camera, gallery, reading, translation, office software (eg WPS Office), short message, browser and other applications.
  • office software eg WPS Office
  • the application framework layer provides an application programming interface (application programming interface, API) and a programming framework for applications in the application layer.
  • the application framework layer includes some predefined functions.
  • the application framework layer may include an input event manager, a window manager, a content provider, a view system, a telephony manager, a resource manager, a notification manager, and the like.
  • the input event manager may include a gesture monitoring module and a sliding event monitoring module.
  • the gesture event monitoring module can be used to monitor gestures, such as three-finger pinch, or gestures such as clicking on a specific control.
  • the sliding event monitoring module can be used to monitor sliding events, such as the touch operation of sliding pages.
  • the gesture monitoring module of the input event manager listens to the gesture event and triggers a system pop-up box that asks the user whether to enter the split-screen translation interface.
  • the input event manager provides sliding event monitoring to the translation APP, which is used to trigger the translation APP to refresh the translation content.
  • a window manager is used to manage window programs.
  • windows can include application windows and public interface windows (ie, system-level windows).
  • the window manager can get the size of the display screen, determine whether there is a status bar, lock the screen, take screenshots, etc.
  • the window manager may include an application split-screen window manager, and the application split-screen window manager may include modules such as split-screen management, window screenshots, and system pop-up windows.
  • the system popup module can be used to start the system popup, and the system popup can be a system popup that asks the user whether to enter the split-screen translation interface.
  • the gesture monitoring module of the input event manager monitors the gesture event, and calls the system pop-up module to start the system pop-up box that asks the user whether to enter the split-screen translation interface.
  • Content providers are used to store and retrieve data and make these data accessible to applications.
  • the data may include video, images, audio, calls made and received, browsing history and bookmarks, phone book, etc.
  • the view system includes visual controls, such as controls for displaying text, controls for displaying pictures, and so on. View systems can be used to build applications.
  • a display interface can consist of one or more views.
  • the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
  • the phone manager is used to provide the communication function of the electronic device 100 .
  • the management of call status including connecting, hanging up, etc.).
  • the resource manager provides various resources for the application, such as localization strings, icons, pictures, layout files, video files and so on.
  • the notification manager enables applications to display notification information in the status bar, which can be used to convey notification-type messages, and can disappear automatically after a brief pause without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc.
  • the notification manager can also display notifications in the status bar at the top of the system in the form of graphs or scroll bar text, such as notifications of applications running in the background, and notifications on the screen in the form of dialog windows. For example, text information is prompted in the status bar, a prompt sound is issued, the electronic device vibrates, and the indicator light flashes.
  • Android Runtime includes core libraries and a virtual machine. Android Runtime is responsible for scheduling and management of the Android system.
  • the core library consists of two parts: one is the function functions that the java language needs to call, and the other is the core library of Android.
  • the application layer and the application framework layer run in virtual machines.
  • the virtual machine executes the java files of the application layer and the application framework layer as binary files.
  • the virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, safety and exception management, and garbage collection.
  • a system library can include multiple functional modules. For example: surface manager (surface manager), media library (Media Libraries), three-dimensional (3D) graphics processing library (eg: OpenGLES), two-dimensional (2D) graphics engine (eg: SGL) and so on.
  • surface manager surface manager
  • media library Media Libraries
  • 3D three-dimensional (3D) graphics processing library
  • 2D two-dimensional (2D) graphics engine
  • the Surface Manager is used to manage the display subsystem and provides a fusion of 2D and 3D layers for multiple applications.
  • the media library supports playback and recording of a variety of commonly used audio and video formats, as well as still image files.
  • the media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
  • the 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
  • 2D graphics engine is a drawing engine for 2D drawing.
  • the kernel layer is the layer between hardware and software.
  • the kernel layer contains at least display drivers, camera drivers, audio drivers, and sensor drivers.
  • the reading APP is turned on on the electronic device, and the reading APP is in full screen mode.
  • a corresponding hardware interrupt is sent to the kernel layer.
  • the kernel layer processes the three-finger pinch touch operation into a first original input event (including the touch sliding coordinate sequence, the start and end timestamps of the touch operation, etc.), and stores the first original input event.
  • the application framework layer obtains the first original input event from the kernel layer, calls the system popup module to trigger the system popup, and asks the user whether to enter the split-screen translation interface.
  • a corresponding hardware interrupt is sent to the kernel layer.
  • the kernel layer processes the clicked touch operation into a second original input event (including touch coordinates, time stamps of the touch operation and other information), and stores the second original input event.
  • the application framework layer obtains the second original input event from the kernel layer, and identifies the control corresponding to the second original input event as a confirmation control in the system pop-up box, such as a "Yes" control.
  • the reading APP is switched from the full-screen mode to the split-screen mode and displayed on one side of the display screen 194 ; the system starts the translation APP in the split-screen mode, and the translation APP is displayed on the other side of the display screen 194 .
  • the existing split-screen management framework of the system is used, and a gesture-triggered system popup frame is added.
  • the gesture monitoring module in the input event manager of the application framework layer implements gesture event monitoring, such as monitoring the touch operation of three-finger pinch, and the gesture event is used to trigger a system pop-up box that asks the user whether to enter the split-screen translation interface.
  • the reading APP switches to the split-screen mode, and starts the translation APP in the split-screen mode.
  • One side of the display screen 194 displays the reading APP, and the other side displays the translation APP.
  • This example implements a split-screen parallel display of the reading content and translation results.
  • the system pop-up frame may be triggered by listening to the user clicking on a specific control.
  • the specific controls may include the controls in the display interface of the reading APP, or the controls in the pull-down notification bar, or the controls in the floating ball, etc.
  • the reading APP when it is detected that the user clicks on the confirmation control in the system pop-up box, the reading APP may not switch to the split-screen mode, but may continue to maintain the full-screen mode, and the translation APP can be displayed as a floating window. mode starts.
  • the reading APP and the first APP are displayed in a split screen
  • the first APP is another APP except the reading APP and the translation APP
  • the system pop-up frame can also be triggered on the reading APP interface.
  • the reading APP can continue to maintain the split-screen mode
  • the translation APP covers the first APP and starts in the split-screen mode.
  • the translation APP obtains a screenshot of the window of another application, such as a reading APP, through the application framework layer, so as to extract text information from the screenshot, and then translate the text information into the target language, and then translate the APP. interface is displayed.
  • the translation APP registers the full-screen sliding event monitoring in the system, and the input event manager of the application framework layer can provide the full-screen sliding event monitoring for the translation APP. That is to say, the translation app can detect the sliding event of the entire display. Therefore, the translation APP can monitor the sliding event of the application on the other side through the application framework layer, such as the sliding page-turning event of the reading APP, so as to realize the dynamic refresh of the translation content.
  • the internal software modules of the translation APP include: user interface (UI) display, sliding event monitoring, screenshot processing, text extraction, translation engine, and voice selection modules.
  • UI display module used to display user interface, etc. For example, translate the various interfaces of the APP, including the main interface, sub-interface, and translation result display interface.
  • Language selection module for selecting source language, and/or target language.
  • the sliding event monitoring module is used to monitor the full-screen sliding event in the split-screen state, such as the sliding page-turning event in the reading APP.
  • the screenshot processing module is used to take a screenshot of the displayed content of the APP on the other side in response to the sliding event monitoring module listening to the sliding event in the split-screen state.
  • the text extraction module is used to extract text information from the screenshot of the displayed content of the APP on the other side.
  • the translation engine module is used to translate the extracted text information into the target language to obtain the final information to be displayed.
  • the translation result display method is a system-level technical solution
  • the translation APP is a system-level application.
  • the technical solutions of the embodiments of the present application do not depend on specific application implementation, and can be supported by any third-party application that supports split-screen display.
  • the following embodiments can be implemented on the electronic device 100 having the above-mentioned hardware structure and software structure.
  • the following embodiments will take a tablet computer as an example to describe the translation result display method provided by the embodiments of the present application. It should be understood that the tablet computer is merely an exemplary description and should not be construed as a limitation of the present application.
  • FIG. 3A it is a schematic flowchart of a method for displaying translation results according to an embodiment of the present application.
  • the reading APP is used as an exemplary description. It should be understood that in other examples of this application, the reading APP can be replaced with other APPs, such as gallery, office software, short message, browser, news, or instant messaging APP, which is not limited in this application.
  • the APP installed on the electronic device may be a native APP provided by the operating system, or may be a third-party APP installed by the user.
  • the electronic device receives an operation of the user clicking on the icon of the reading APP installed on the tablet computer, and in response to the operation, opens the reading APP and displays the reading interface.
  • the reading interface may be a historical reading interface, or a main interface of a reading APP, or the like.
  • the gesture event may include that the tablet computer monitors that the user performs a preset touch operation on any display interface of the reading APP.
  • Preset touch operations include, but are not limited to, a three-finger pinch operation, or operations such as clicking on a specific control.
  • the specific controls are preset controls, which may include preset controls in the menu bar of the display interface of the reading APP, preset controls in the pull-down notification bar, or preset controls in the floating ball, and the like.
  • the preset touch operations that trigger the system pop-up frame may include but are not limited to: single-finger or multiple-finger long-press operations, multiple-finger pinch operations (or shrinking) operation, multi-finger zooming (or expanding) operation, knuckle tapping operation, single-finger or multi-finger sliding operation according to a preset trajectory, etc.
  • the single-finger or multi-finger long-press operation includes an operation in which the duration of single-finger or multiple-finger pressing on the touch screen exceeds a first duration, where the first duration is a duration threshold.
  • Multi-finger pinch-in or zoom-in operations include two-finger, three-finger, four-finger, or five-finger pinch-in or zoom-in operations.
  • Knuckle-tapping operations include single- or multi-knuckle click, double-tap, or triple-tap on the touch screen.
  • Single-finger or multi-finger sliding according to a preset track includes operations such as single-finger or multi-finger sliding up, down, left or right on the touch screen.
  • the tablet computer detects that the user performs a three-finger pinch touch operation on the display interface of the reading APP.
  • the system popup is triggered.
  • the words "whether to enter the split-screen translation interface" are displayed in the system pop-up box loaded on the tablet computer.
  • the system popup also includes selection controls, "Yes” and "Cancel”.
  • the confirmation operation refers to a user operation of agreeing to enter the translation split-screen translation interface.
  • a preset voice control operation such as "confirm to enter the split-screen translation interface” or “confirm” may be input by the user's voice. Enter the split-screen display state after receiving the confirmation operation input by the user, which can prevent the split-screen translation function caused by misoperation.
  • Cancel operation refers to the user operation that does not agree to enter the translation split-screen translation interface. For example, the touch operation of the "Cancel" control in the system pop-up box shown in FIG. 3B can be clicked.
  • the split-screen display state is to set the display area of the reading APP on the left half, and set the display area of the translation APP on the right half, as shown in FIG. 3C ; Or, set the display area of the reading APP to the right half, and set the display area of the translation APP to the left half.
  • the split-screen display state is to set the display area of the reading APP in the upper half, and set the display area of the translation APP in the lower half, as shown in Figure 3D; or, set the display area of the reading APP to the upper half. In the lower half, set the display area of the translation app to the upper half.
  • the split screen adopts a landscape display layout, and the left and right split screens are displayed. If the tablet computer is currently in a vertical screen, the split screen adopts a vertical screen display layout, and the upper and lower screens are displayed in a split screen.
  • the vertical screen display layout or the horizontal screen display layout of the split screen may or may not occupy the entire display screen.
  • the vertical screen display layout or the horizontal screen display layout occupies the entire display screen, more content can be displayed at the same time, which is convenient for users to view.
  • the display area of the translation APP and the display area of the reading APP may have the same size, or may have different sizes.
  • the size of the display area of the reading APP and the translation APP can be set by the system by default, or it can be adaptively adjusted by the system according to the content of the display area, or it can be set by the user according to the size of the display screen and individual needs.
  • the size of the display interface of the translation APP and the reading APP can be adjusted by the system according to the amount of displayed content, which is convenient for the user to view.
  • S340 Receive the source language and the target language selected by the user on the translation APP.
  • the source language is the language of the text on the reading app.
  • the target language is the language in which the translation results belong.
  • the target language is usually the user's native language; alternatively, a language in which the user is not dyslexic.
  • a language switching control is provided on the display interface of the translation APP, which can be used by the user to switch the source language and the target language.
  • a source language switching control 31 and a target language switching control 32 are set on the display interface of the translation APP.
  • a language input control is provided on the display interface of the translation APP, which can allow the user to input the source language and the target language.
  • a language input control is provided on the display interface of the translation APP, which can allow the user to input the source language and the target language.
  • two input boxes are set on the display interface of the translation APP, one input box is used for inputting the source language, and the other input box is used for inputting the target language.
  • the translation APP can automatically identify the language of the text information to be translated in the reading APP, and use this language as the source language. In these embodiments, the user is no longer required to select the source language, simplifying user operations.
  • the translation APP may record the user's historical usage habits, and determine the target language according to the user's historical usage habits. In these embodiments, the user is no longer required to select the target language, simplifying the user operation.
  • the source language is English and the target language is Chinese for illustrative description. It should be understood that this example should not be construed as a limitation of the present application.
  • the translation APP After determining the source language and the target language, the translation APP translates the text information on the display interface of the reading APP into the target language, and displays the translation result.
  • the translation APP translates the text information in the text format in the reading APP.
  • the translation APP will read the English "Walk into Switzerland Switzerland Switzerland is rich in tourism resources and has a reputation as a world park.” in the text format of the APP, and translate it into Chinese: “Walk into Switzerland Switzerland tourism resources It is rich and has the reputation of a world park.”
  • the translation APP translates text information in one or more formats of text formats, pictures, or layout content in the reading APP. For example, as shown in Figure 3G, the translation APP translates the English text in the text format in the reading APP and the picture, and displays the translation result.
  • the displayed content can be in text format, pictures, layout controls, or any other user-visible file display.
  • the displayed content in these formats can be translated and displayed on the translation app.
  • step S350 includes steps S410 to S440.
  • step S410 is started to obtain a display screenshot of the reading APP.
  • the translation APP calls the system interface to take a screenshot of the entire screen of the tablet computer, and the size of the screenshot is the size of the entire screen.
  • FIG. 4B is an example of a screenshot of the entire screen.
  • the translation APP obtains the size of its own window area, and obtains the width and height of the tablet.
  • the translation APP can obtain the window area size of the reading APP according to the width and height of the tablet computer and the size of its own window area.
  • a picture of the window area of the reading APP is obtained in the screenshot of the entire screen.
  • FIG. 4B it is an example of a screenshot of the window area of the reading APP.
  • the text in the displayed screenshot is extracted through an Optical Character Recognition (Optical Character Recognition, OCR) technology.
  • OCR Optical Character Recognition
  • the translation engine translates the extracted text into text in the target language to be finally displayed, that is, a translation result.
  • the translation APP has completed the translation of the text information to be translated in the reading APP.
  • the user can quickly enter the split-screen display state through a simple operation, so that the user can quickly obtain the translation result, thereby improving the efficiency of translation and reading.
  • the display screen displays the translation APP and the reading APP at the same time, which increases the amount of information displayed on the display screen and improves the efficiency of multi-task interaction.
  • the user operation that triggers the system pop-up frame may not be limited to the gesture touch operation, but may also include a voice control operation of inputting a preset voice, a preset cursor control operation, and the like.
  • the tablet computer detects the user's voice input preset voice, such as "split-screen translation” or "enter split-screen translation” through the voice assistant, and triggers the system pop-up box.
  • the user controls the cursor movement through the physical keyboard or mouse of the tablet computer, and controls the cursor to hover to the position of the preset button on the display interface of the reading APP. If the user clicks the mouse, or hovers over the preset button If the position of the button exceeds the second time period, the system popup will be triggered.
  • the second duration is a duration threshold.
  • the tablet computer after the tablet computer detects the voice control operation of the user inputting the preset voice, or the preset gesture touch operation, or the preset cursor control operation, it is not necessary to trigger the system pop-up box,
  • the translation APP also does not need to receive the confirmation operation input by the user.
  • the tablet computer enters a split-screen display state in response to a voice control operation, a preset gesture touch operation, or a preset cursor control operation inputting a preset voice by the user, with the reading APP displayed on one side and the translation displayed on the other side. APP. In this way, the user operation is further simplified, the user interaction cost is reduced, and the operation efficiency is improved.
  • the first APP is an APP other than the translation APP and the reading APP, such as instant messaging. APP, etc.
  • the user can also trigger the system popup on the display interface of the reading APP. If the user triggers the system popup, and the tablet computer receives the confirmation input from the user to perform the operation of the split-screen translation interface, the translation APP starts in the split-screen mode by covering the first APP, as shown in FIG. 5A .
  • the first APP is activated, and starts in a split-screen mode in a manner of covering the translation APP.
  • the user when the display interface of the reading APP and the display interface of the translation APP are in a split-screen display state, the user returns to the desktop, for example, clicks the home button to return to the desktop, or switches from recent tasks to For other applications, when switching back to the reading APP again, the reading APP and the translation APP will still be displayed in split-screen mode.
  • the system when an operation of returning to the desktop or switching to other tasks inputted by the user is received, the system records the split-screen display state of the reading APP and the translation APP, and switches the reading APP and the translation APP to the stop state, When receiving the user's operation of activating the reading APP, the system activates the reading APP and the translation APP according to the split-screen display status of the reading APP and the translation APP, and displays them in the split-screen mode. That is to say, in these embodiments, after the reading APP and the translation APP form a split screen, the display interfaces of the two applications, that is, the windows, are bound together. Whether it is to return to the desktop or enter other applications, and then activate the reading APP, the reading APP And the translation app is still displayed in a split-screen state.
  • the tablet computer after the tablet computer detects a voice control operation, a preset gesture touch operation, or a preset cursor control operation that the user inputs a preset voice, or, the tablet computer receives an input from the user. After confirming the operation, the tablet computer responds to the voice control operation, or the preset gesture touch operation, or the preset cursor control operation, or the confirmation operation, and the reading APP can keep the original display interface size, such as full-screen display, and can also avoid the translation of the APP.
  • the occlusion is scaled to the preset size, and the translation APP is superimposed and displayed on the reading APP in a floating window mode, for example, as shown in Figure 5B.
  • the floating window may be a transparent or opaque floating window.
  • the size of the display area of the reading APP and the translation APP can be set by the system by default, or can be set by the user according to the size of the display screen and individual needs.
  • a full-screen and zoom display control 51 may be set on the suspension window of the translation APP, and/or the exit suspension window control 52 may be set.
  • the user can switch between the full screen display and the floating window display by clicking the full screen and zoom display control 51 .
  • the user can click the exit suspension window control 52 to exit the suspension window, that is, close the translation APP.
  • dragging the border of the translation APP floating window can enlarge or reduce the floating window.
  • the translation APP is superimposed and displayed on the reading APP in a floating window mode
  • a mobile control may be set on the floating window of the translation APP.
  • the moving control can be the top horizontal bar 53, and the user can drag the top horizontal bar 53 of the floating window to move the position of the floating window.
  • the floating window may be switched to a split screen through the received operation of the user acting on the mobile control.
  • the tablet computer when the tablet computer is currently in landscape orientation, long press the horizontal bar 53 at the top of the floating window and drag it to the left or right to switch to the split-screen state.
  • FIG. 5C when the horizontal bar 53 at the top of the floating window is long-pressed and dragged to the left to switch to the split-screen state, the split-screen window of the translation APP is on the left half, and the split-screen window of the reading APP is on the right half; long-press the top of the floating window
  • the split-screen window of the translation APP is on the right half, and the split-screen window of the reading APP is on the left half.
  • the tablet computer when the tablet computer is currently in a vertical screen, long press the horizontal bar 53 at the top of the floating window and drag it upwards or downwards to switch to the split screen state.
  • FIG. 5D when long-pressing and dragging the horizontal bar 53 on the top of the floating window to switch to the split-screen state, the split-screen window of the translation APP is on the upper half, and the split-screen window of the reading APP is on the lower half; long-press the horizontal bar on the top of the floating window 53
  • the split-screen window of the translation app When dragging down to switch to the split-screen state, the split-screen window of the translation app is on the bottom half, and the split-screen window of the reading app is on the top half.
  • the landscape display layout is adopted, and the left and right split-screen displays are used. If the tablet computer is currently in a vertical screen, the vertical screen display layout is adopted, and the upper and lower screens are displayed.
  • the split screen may be switched to a floating window through a received user operation.
  • the split screen window of the reading APP and/or the translation APP can be set with full screen and zoom display controls 51 , and/or exit split screen controls 52 , and/or move controls.
  • the movement control can be the top bar 53 .
  • the tablet is currently in landscape orientation.
  • the split-screen window of the translation APP is on the left half, and the split-screen window of the reading APP is on the right half. Long press the top horizontal bar 53 of the translation APP split screen window and drag it to the right to switch to the floating window.
  • the size of the split screen window of the reading APP can be expanded to the entire display screen.
  • the split-screen window of the translation APP is on the left half, and the split-screen window of the reading APP is on the right half. Long press the top horizontal bar 53 of the split screen window of the reading APP and drag it to the left to switch to the floating window.
  • the size of the split screen window of the translation APP can be expanded to the entire display screen.
  • tablet computers are currently in portrait orientation.
  • the split-screen window of the translation app is on the upper half, and the split-screen window of the reading app is on the bottom half. Long press the top bar 53 of the translation APP split-screen window and drag it downward to switch to the floating window.
  • the size of the split-screen window of the reading APP can be expanded to the entire display screen.
  • the split-screen window of the translation APP is on the upper half, and the split-screen window of the reading APP is on the lower half. Long press the top horizontal bar 53 of the split screen window of the reading APP and drag it upward to switch to the floating window.
  • the size of the split screen window of the translation APP can be expanded to the entire display screen.
  • the other three embodiments of the present application provide another three translation result display methods.
  • the other three embodiments of the present application are described by taking improvements based on the embodiment shown in FIG. 3A as an example.
  • the embodiment of the present application further includes steps S610 to S620 after step S350 .
  • the reading APP displays new text
  • the translation APP translates the new text displayed on the reading APP, and refreshes the display.
  • the sliding operation of the reading APP refers to a user sliding operation that triggers a page turning event, that is, a user operation that triggers an update of the displayed content.
  • the translation APP registers full-screen sliding event monitoring in the system, and the input event manager of the application framework layer can provide full-screen sliding event monitoring to the translation APP. Therefore, the translation APP can determine whether a page turning event occurs in the reading APP by detecting the sliding event of the entire display screen. If the user's sliding operation on the display interface of the reading APP is received, it can be considered that a page turning event occurs in the reading APP, so that the translation APP translates the new text and refreshes the display.
  • a sliding event usually consists of a down event, a sequence of several move events, and a release (up) event.
  • the processing logic of the sliding event monitored by the translation APP includes: receiving a down event and a move event, deeming that a sliding event occurs, recording the sliding coordinate sequence until the up event is received, and judging the coordinate position according to the triggering of the up event, Determine whether the entire sliding coordinate sequence is in the display area of the reading APP. If so, it is considered that a valid sliding event has occurred.
  • the translation APP translates the new text displayed on the reading APP and refreshes the display; if not, it is considered to have occurred.
  • the swipe event is invalid, and the translation APP does not respond.
  • the processing logic of the reading APP monitoring sliding events is the same. For valid sliding events, the reading APP performs the page-turning function, that is, the display content is updated; and for invalid sliding events, the reading APP does not respond, that is, does not update the display content. .
  • the sliding operation includes a sliding operation of turning to the previous page or the next page, for example, the operation of turning left or upward to turn the previous page, or the downward or right sliding operation of turning to the next page Page operation, etc.
  • the reading APP triggers a page-turning event
  • the translation APP obtains the display screenshot of the reading APP, extracts the text from the display screenshot, and submits the extracted text to the translation engine for translation, and the translation result is obtained, thereby refreshing the display.
  • the process of refreshing and displaying the translation APP is similar to the process of displaying the translation result in step S350 of the embodiment shown in FIG. 3A , and the difference lies in the different triggering conditions, which will not be repeated here.
  • the tablet computer is currently in a landscape display layout, which is a left-right split-screen display.
  • the left half is the split screen window of the reading app
  • the right half is the split screen window of the translation app.
  • the tablet computer receives the upward swipe operation input by the user in the split-screen window of the reading APP.
  • the reading APP displays the content of the next page
  • the translation APP translates according to the new text displayed by the reading APP, and displays the new translation result.
  • the translation interface can automatically and synchronously display the translation result of the new content. Therefore, user operations are simplified, user interaction costs are reduced, and efficiency is improved.
  • the embodiment of the present application further includes steps S710 to S720 after step S350 .
  • the translation APP in response to the refresh translation operation, the translation APP translates the text currently displayed on the reading APP, and refreshes the display.
  • the translation APP adds a manual refresh translation function, which can manually display the text content and the translation result at the same time, so that the embodiment of the present application is suitable for more application scenarios, and more Universal.
  • the tablet computer receives the refresh translation operation input by the user, and enables the refresh translation function of the translation app.
  • the refresh translation operation may include a touch operation, a voice control operation, and/or a cursor control operation, and the like.
  • Touch operations include touch operations such as clicking on a preset control or sliding according to a preset track.
  • the voice control operation includes a voice control operation of inputting a preset voice.
  • Cursor control operations include controlling the cursor to hover over the position of the preset control, etc.
  • the translation APP when monitoring the refresh translation operation input by the user, the translation APP obtains the current display screenshot of the reading APP, extracts the text from the current display screenshot, submits the extracted text to the translation engine for translation, and obtains the translation result, thereby refreshing the display .
  • the process of refreshing and displaying the translation APP is similar to the process of displaying the translation result in step S350 of the embodiment shown in FIG. 3A , and the difference lies in the different triggering conditions, which will not be repeated here.
  • a refresh control 71 is set on the display interface of the translation APP.
  • the translation APP After receiving the user's click operation on the refresh control, the translation APP obtains the display screenshot of the reading APP, and obtains the translation according to the display screenshot. As a result, the display is refreshed.
  • the tablet computer receives a preset voice control operation of the user's voice input, such as the user's voice input "refresh translation” or "refresh translation result”.
  • the translation APP obtains the display screenshot of the reading APP, and obtains the translation result according to the display screenshot, thereby refreshing the display.
  • the embodiment of the present application further includes steps S810 to S820 after step S350 .
  • the translation APP registers a full-screen user operation event monitoring in the system.
  • the input event manager of the application framework layer can provide full-screen user operation event monitoring to the translation APP.
  • the tablet computer receives the user operation input by the user on the display interface of the reading APP, and translates the APP to obtain the current display screenshot of the reading APP. Compare the current display screenshot with the historical display screenshot, and judge whether the reading APP displays new text according to the comparison result. If it is determined that the reading APP displays new text, the new text displayed on the reading APP will be translated and the display will be refreshed; if it is determined that the reading APP does not display new text, the current display screenshot will not be translated and the display will not be refreshed.
  • the process of refreshing and displaying the translation APP is similar to the process of displaying the translation result in step S350 of the embodiment shown in FIG. 3A , and the difference lies in the different triggering conditions, which will not be repeated here.
  • the display screenshot of the history may be the display screenshot of the reading APP obtained last time by the translation APP.
  • a global or local comparison scheme may be adopted, which is not limited in this application.
  • the embodiment of the present application can also realize the simultaneous display of the text content and the translation result. Compared with the embodiment shown in FIG. 6A , the specific sliding page-turning event is no longer monitored, so that the embodiment of the present application is applicable to more application scenarios and is more universal. Compared with the embodiment shown in FIG. 7A , user operations are reduced, and interaction costs are reduced.
  • FIG. 9A it is a schematic flowchart of a method for displaying translation results according to an embodiment of the present application.
  • the translation result display method provided in this embodiment involves a cross-device connection scenario.
  • a first electronic device is connected to a second electronic device across devices
  • the translation result of the content displayed by the first electronic device can be displayed on the second electronic device.
  • FIG. 9B an exemplary application scenario of this embodiment is shown.
  • a mobile phone is used as an example of the first electronic device
  • a tablet computer is used as an example of the second electronic device.
  • a translation result display method includes steps S910 to S950. It should be understood that for the steps in this embodiment that are the same as those in the foregoing embodiments, please refer to the corresponding descriptions of the foregoing embodiments, and details are not repeated here.
  • the mobile phone receives the operation of the user to open the reading APP, and opens the reading APP.
  • the mobile phone triggers a system pop-up frame in response to the monitored gesture event, where the system pop-up frame is a system pop-up frame that asks the user whether to enter a synchronous translation state.
  • the gesture event is a three-finger pinch event.
  • the mobile phone triggers the system popup in response to the three-finger pinch event.
  • the user operation that triggers the system pop-up frame may include: a preset voice voice control operation, a preset gesture touch operation, or a preset cursor control operation, and the like.
  • the mobile phone receives the confirmation operation input by the user, and displays the device list.
  • the device list may include receivable electronic devices of the local machine and/or surrounding areas.
  • the device list may include the device and/or the receivable electronic device with a display screen around it.
  • the mobile phone displays a device list in response to the user's operation of clicking the "Yes" control.
  • the process of establishing a connection between a mobile phone and a peripheral receivable device may include steps such as discovery and connection, or steps such as discovery, authentication and connection.
  • the mobile phone may search for nearby receivable devices through a BT module, an NFC module, or a Wi-Fi module, etc., and then display a device list of the receivable devices.
  • a target device in the device list such as a tablet computer
  • a Wi-Fi direct connection, a hotspot, or an ultra-wideband (ultra-wideband) connection between the mobile phone and the tablet computer can be established.
  • UWB ultra-wideband
  • a wired connection relying on a USB data cable or the like may also be established between the electronic devices to realize information transmission.
  • a wireless communication connection can also be established between electronic devices by scanning a code to realize information transmission. It should be understood that the embodiments of the present application do not specifically limit the manner of establishing a wireless or wired communication connection between electronic devices, and any manner of implementing a cross-device connection can be used in the present application.
  • the mobile phone receives a click operation of the user selecting a tablet computer in the device list, and establishes a communication connection with the tablet computer, where the tablet computer is a device in the device list.
  • the mobile phone After the mobile phone receives the click operation of selecting the tablet computer input by the user, the mobile phone establishes a connection with the tablet computer.
  • the mobile phone obtains the currently displayed content in the reading APP, and displays the translation result of the currently displayed content in the reading APP of the mobile phone on the tablet computer.
  • the mobile phone after the mobile phone receives a click operation input by the user to select the tablet computer, the mobile phone establishes a communication connection with the tablet computer.
  • the information exchange between the two is realized based on the communication connection established by the two, and the mobile phone can obtain the device capability of the tablet computer to determine whether the tablet computer has the translation function.
  • the tablet has translation capabilities.
  • the mobile phone sends the synchronous translation instruction to the tablet computer, and the tablet computer starts the translation APP according to the received synchronous translation instruction.
  • the translation APP can allow the user to input the source language and/or the target language.
  • the tablet computer sends a language determination instruction to the mobile phone.
  • the mobile phone receives the language determination instruction, it obtains the display screenshot of the reading APP, and sends the display screenshot to the tablet computer through the connection established between the mobile phone and the tablet computer.
  • the tablet computer obtains a display screenshot, extracts the text information in the display screenshot, and after translating the text information into a corresponding language, displays the translation result on its own display screen.
  • the translation APP does not require the user to input the source language and/or the target language
  • the translation APP can identify the language in which the displayed content of the reading APP is read as the source language, and the target language can be determined according to the user's historical usage habits.
  • the mobile phone obtains the display screenshot of the reading APP, and sends the display screenshot to the tablet computer through the communication connection established between the mobile phone and the tablet computer.
  • the tablet computer obtains a display screenshot, extracts the text information in the display screenshot, and after translating the text information into the corresponding target language, displays the translation result on its own display screen.
  • the tablet has translation capabilities. It should be understood that in these actual scenarios, if the mobile phone has a translation function, the displayed content of the reading APP can also be translated on the mobile phone side to obtain the translation result, and then the translation result can be displayed on the tablet computer. When the process of obtaining the translation result is performed on the mobile phone, the mobile phone sends the translation result to the tablet computer through the communication connection established between the mobile phone and the tablet computer. It should also be understood that the process of translating the displayed content of the reading APP to obtain the translation result may be partially performed on a mobile phone and partially performed on a tablet computer. This application does not limit the executive body of this process.
  • the tablet computer may refresh the display, that is, refresh and display the translation result.
  • the refresh of translation results can be achieved automatically or manually.
  • the mobile phone receives a sliding operation input by the user in the reading APP, where the sliding operation is a sliding page turning operation.
  • the mobile phone updates the display content on the display interface of the reading APP.
  • the tablet computer displays the translation result of reading the updated display content of the APP.
  • the system monitors the sliding event of the reading APP, and in response to the sliding event input by the user, such as sliding a finger upward, the reading APP updates the displayed content and displays the next page.
  • the tablet computer displays the translation result of reading the updated display content of the APP.
  • the process of getting the translation results can be done on a mobile phone or tablet.
  • the mobile phone receives a refresh translation operation input by the user, and in response to the refresh translation operation, the mobile phone obtains the current display content of the reading APP, and instructs the tablet computer to display the translation result of the currently displayed content of the reading APP.
  • the mobile phone monitors the "refresh translation result" input by the user's voice, and controls the tablet computer to display the translation result corresponding to the currently displayed content of the reading APP. Specifically, the mobile phone obtains the current display screenshot of the reading APP, then extracts the text information of the currently displayed screenshot on the mobile phone or tablet computer, translates the text information to obtain the translation result, and finally displays the translation result on the tablet computer.
  • the tablet computer receives a refresh translation operation input by the user, and in response to the refresh translation operation, sends a refresh translation instruction to the mobile phone, and the mobile phone obtains the current display content of the reading APP according to the refresh translation instruction, and instructs the tablet computer to display Read the translation result of the content currently displayed in the APP.
  • the tablet computer detects that the user clicks the "refresh" control of the display interface of the translation APP, and the tablet computer obtains the translation result corresponding to the current display content of the reading APP, and Display the translation result.
  • the tablet computer detects that the user clicks on the "refresh" control of the display interface of the translation APP, and sends a request for obtaining a screenshot of the current display of the reading APP to the mobile phone, and the mobile phone responds to the obtaining request, obtains the current display screenshot of the reading APP, and then displays the screenshot. Feedback to tablet.
  • the tablet computer extracts the text information currently displayed in the screenshot, translates the text information to obtain the translation result, and finally displays the translation result on the tablet computer. It should be understood that, in other examples, the process of extracting text information, and/or the process of translating text information to obtain a translation result, may be performed on a mobile phone.
  • the mobile phone receives a user operation input by the user in the reading APP; the mobile phone determines whether the reading APP has updated the display content in response to the user operation, and if the reading APP has updated the display content, obtains the updated content of the reading APP. and instructs the tablet computer to display the translation result of the updated display content of the reading APP; if the reading APP does not update the display content, no response is executed.
  • the mobile phone monitors any user operation of the reading APP, and in response to any user operation input by the user, determines whether the reading APP has updated the displayed content page. If the reading APP updates the display content, obtain the updated display content of the reading APP, and instruct the tablet computer to display the translation result of the updated display content of the reading APP.
  • the tablet does not have translation capabilities. It should be understood that in these actual scenarios, the mobile phone has a translation function, and the mobile phone invokes the display function of the tablet computer.
  • the mobile phone after the mobile phone establishes a connection with the tablet computer, the mobile phone starts the translation APP.
  • the translation APP can allow the user to input the source language and/or the target language.
  • the mobile phone After obtaining the source language and/or target language input by the user, the mobile phone obtains a display screenshot of the reading APP.
  • the mobile phone extracts the text information in the displayed screenshot, and after translating the text information into the corresponding language, the translation result is sent to the tablet computer through the connection established between the mobile phone and the tablet computer.
  • the tablet displays the translation results in its own display.
  • the display interface of the translation APP on the mobile phone may be displayed simultaneously with the display interface of the reading APP, and the translation APP is provided with controls for the user to input the source language and the target language.
  • Controls can include selection controls or input box controls.
  • the translation APP does not require the user to input the source language and the target language
  • the translation APP recognizes the language in which the displayed content of the APP is read as the source language, and determines the target language according to the user's historical usage habits.
  • the mobile phone obtains the display screenshot of the reading APP.
  • the mobile phone extracts the text information in the displayed screenshot, and after translating the text information into the corresponding language, the translation result is sent to the tablet computer through the connection established between the mobile phone and the tablet computer.
  • the tablet displays the translation results in its own display. It should be understood that the translation APP on the mobile phone may not be displayed and run in the background.
  • the cross-device connection scenario according to the capabilities of the tablet computer, it may be determined to perform translation on the mobile phone or/tablet computer to obtain the translation result, and then display the translation result on the tablet computer.
  • the technical solution of the present application is implemented based on a cross-device connection scenario.
  • One device displays the reading content, and the other device synchronously displays the translation result.
  • the usage scenarios of the embodiments of the present application are expanded, and the environmental adaptability of the embodiments of the present application is greatly improved. ;
  • the display screens of the two devices are fully utilized, improving the user's reading efficiency.
  • the mobile phone may display a device list after monitoring a gesture event or the like.
  • User operations are simplified and user interaction costs are reduced.
  • the mobile phone and the tablet computer may establish a communication connection in advance.
  • the mobile phone monitors the gesture event, it obtains the current display content of the reading APP, and instructs the tablet computer to display the current content of the reading APP. Displays the translation result of the content.
  • the mobile phone after the mobile phone monitors gesture events, etc., it can establish a communication connection with the tablet computer according to the historical connection record. Then, the mobile phone sends the content to be translated or the translation result of the reading APP to the tablet computer, and the tablet computer translates the content to be translated into the target language and displays it, or displays the translation result after receiving the translation result.
  • the user may select a local machine, that is, a mobile phone, in the device list.
  • the mobile phone has a translation function.
  • the translation APP is started, and the display interface of the translation APP is displayed, and the display interface of the translation APP and the display interface of the reading APP are displayed at the same time.
  • the translation result for the displayed content of the reading APP is displayed on the display interface of the translation APP.
  • the mobile phone can establish a communication connection with multiple tablet computers, so as to perform data interaction with the multiple tablet computers, and display the translation results on the multiple tablet computers.
  • translation results in different target languages may be displayed on different tablet computers according to the user's historical usage habits or different target languages input by the user.
  • the embodiment of the present application further provides a translation result display device, and each module of the translation result display device can correspond to each step of the translation result display method.
  • Embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps in the foregoing method embodiments can be implemented.
  • the embodiments of the present application provide a computer program product, when the computer program product runs on an electronic device, the steps in the foregoing method embodiments can be implemented when the electronic device executes.
  • the integrated modules/units if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium.
  • the present application realizes all or part of the processes in the methods of the above embodiments, which can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium.
  • the computer program includes computer program code
  • the computer program code may be in the form of source code, object code, executable file or some intermediate form, and the like.
  • the computer-readable medium may include at least: any entity or device capable of carrying the computer program code to the photographing device/electronic device, recording medium, computer memory, read-only memory (ROM), random access memory (Random Access Memory, RAM), electrical carrier signals, telecommunication signals, and software distribution media.
  • ROM read-only memory
  • RAM random access memory
  • electrical carrier signals telecommunication signals
  • software distribution media For example, U disk, mobile hard disk, disk or CD, etc.
  • computer readable media may not be electrical carrier signals and telecommunications signals.
  • the units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Artificial Intelligence (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The present application belongs to the technical field of computers. Provided are a translation result display method and apparatus, and an electronic device. The method comprises: in response to a first operation input by a user in a first application, displaying a display interface of the first application and a display interface of a second application in a split screen manner, or superimposing the display interface of the second application onto the display interface of the first application, with the second application being a translation application; translating the current display content in the first application into a target language to obtain a translation result; and displaying the translation result in the display interface of the second application. The embodiments of the present application can solve the technical problem in the related art of cumbersome user operation and a low efficiency during a translation process.

Description

翻译结果显示方法、装置及电子设备Translation result display method, device and electronic device
本申请要求于2020年7月2日提交国家知识产权局、申请号为202010630277.8、申请名称为“翻译结果显示方法、装置及电子设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application with the application number 202010630277.8 and the application name "translation result display method, device and electronic equipment" submitted to the State Intellectual Property Office on July 2, 2020, the entire contents of which are incorporated by reference in in this application.
技术领域technical field
本申请属于计算机技术领域,尤其涉及一种翻译结果显示方法、装置及电子设备。The present application belongs to the field of computer technology, and in particular relates to a translation result display method, device and electronic device.
背景技术Background technique
随着终端技术的蓬勃发展,电子设备极大地丰富了用户的生活,也为用户提供了生活便利。用户可以利用电子设备上安装的各种应用程序(Application,APP)获取信息,进行社交、购物或娱乐等。例如:即时通讯APP、阅读APP和翻译APP等。With the vigorous development of terminal technology, electronic devices have greatly enriched the life of users and provided users with convenience in life. Users can obtain information by using various application programs (Application, APP) installed on the electronic device, and conduct social networking, shopping or entertainment. For example: instant messaging apps, reading apps and translation apps, etc.
用户使用电子设备时,常常会遇到不同语言的信息。如果用户不具备足够的语言知识,将会产生阅读障碍,这时就需要借助翻译软件或翻译工具等来解决这个问题。When users use electronic devices, they often encounter information in different languages. If the user does not have sufficient language knowledge, dyslexia will occur, and translation software or translation tools are needed to solve this problem.
为了扫除在使用电子设备阅读时遭遇的语言障碍,用户通常会在电子设备上安装翻译软件。用户在第一APP看到生词或句子等时,需要退出第一APP,打开翻译APP。在翻译APP的查询框中输入待翻译内容,获得翻译结果。当查询完待翻译内容后,用户需要退出翻译APP,进而切换到第一APP。可见,整个翻译过程,用户操作相当繁琐,效率低下。In order to remove language barriers encountered when reading on electronic devices, users usually install translation software on electronic devices. When users see new words or sentences in the first app, they need to exit the first app and open the translation app. Enter the content to be translated in the query box of the translation app to get the translation result. After querying the content to be translated, the user needs to exit the translation app, and then switch to the first app. It can be seen that in the entire translation process, user operations are quite cumbersome and inefficient.
发明内容SUMMARY OF THE INVENTION
本申请实施例提供了一种翻译结果显示方法、装置及电子设备,可以解决相关技术在翻译过程用户操作繁琐,效率低下的技术问题。The embodiments of the present application provide a translation result display method, device and electronic device, which can solve the technical problems of complicated user operations and low efficiency in the translation process of the related art.
第一方面,本申请实施例提供了一种翻译结果显示方法,包括:In the first aspect, an embodiment of the present application provides a method for displaying translation results, including:
响应于用户在第一应用中输入的第一操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上,所述第二应用为翻译应用;In response to the first operation input by the user in the first application, the display interface of the first application and the display interface of the second application are displayed in a split screen; or, the display interface of the second application is superimposed and displayed on the On the display interface of the first application, the second application is a translation application;
将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果;Translating the currently displayed content in the first application into a target language to obtain a translation result;
在所述第二应用的显示界面显示所述翻译结果。The translation result is displayed on the display interface of the second application.
在第一方面的实施例中,通过简单的用户操作就能够在第二应用中显示第一应用当前显示内容的翻译结果,减小了交互成本,提高了效率。此外,同时显示第一应用和第二应用的显示界面,即显示屏同时显示内容和翻译结果,增加了显示屏显示的信息量,提高了多任务交互的效率。In the embodiment of the first aspect, the translation result of the content currently displayed by the first application can be displayed in the second application through a simple user operation, which reduces the interaction cost and improves the efficiency. In addition, the display interfaces of the first application and the second application are displayed at the same time, that is, the display screen simultaneously displays the content and the translation result, which increases the amount of information displayed on the display screen and improves the efficiency of multi-task interaction.
作为第一方面的一实现方式,所述响应于用户在第一应用中输入的第一操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上,包括:As an implementation manner of the first aspect, the display interface of the first application and the display interface of the second application are displayed in a split screen in response to the first operation input by the user in the first application; The display interface of the second application is superimposed and displayed on the display interface of the first application, including:
响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;In response to the first operation input by the user in the first application, a system pop-up box is triggered, and the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若接收到用户针对所述系统弹框输入的确认操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上。If the user's confirmation operation for the system pop-up box input is received, the display interface of the first application and the display interface of the second application are displayed in a split screen; or, the display interface of the second application is superimposed and displayed on the on the display interface of the first application.
在第一方面的一实现方式中,增加了系统弹框的触发,避免了因用户误操作显示第二应用的显示界面,提高了方案的防误触性能。In an implementation manner of the first aspect, the triggering of the system pop-up frame is added, which prevents the display interface of the second application from being displayed due to user misoperation, and improves the anti-mistouch performance of the solution.
作为第一方面的一实现方式,在所述将所述第一应用中的显示内容翻译成目标语言,获得翻译结果之前,还包括:As an implementation manner of the first aspect, before translating the display content in the first application into a target language and obtaining a translation result, the method further includes:
获取用户在所述第二应用中输入的源语言和/或目标语言。Obtain the source language and/or target language input by the user in the second application.
在第一方面的一实现方式中,可以由用户自行输入源语言和/或目标语言,可以适应用户需求,提高了方案的多样性。In an implementation manner of the first aspect, the source language and/or the target language can be input by the user, which can adapt to the user's needs and improve the diversity of solutions.
在第一方面的一实现方式中,在分屏显示所述第一应用的显示界面和所述第二应用的显示界面的情形下,所述方法还包括:In an implementation manner of the first aspect, in a situation where the display interface of the first application and the display interface of the second application are displayed in a split screen, the method further includes:
响应于用户在所述第一应用的显示界面或所述第二应用的显示界面输入的第四操作,所述第一应用的显示界面或所述第二应用的显示界面切换为悬浮窗。In response to a fourth operation input by the user on the display interface of the first application or the display interface of the second application, the display interface of the first application or the display interface of the second application is switched to a floating window.
在第一方面的一实现方式中,在将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上的情形下,所述方法还包括:In an implementation manner of the first aspect, when the display interface of the second application is superimposed and displayed on the display interface of the first application, the method further includes:
响应于用户在所述第二应用的显示界面输入的第五操作,所述第一应用的显示界面和所述第二应用的显示界面切换为分屏显示。In response to a fifth operation input by the user on the display interface of the second application, the display interface of the first application and the display interface of the second application are switched to split-screen display.
在第一方面的一实现方式中,可以通过简单的用户操作实现分屏显示与叠加显示的切换,显示屏的显示模式可以根据用户需求快速切换,提高了交互效率。In an implementation manner of the first aspect, switching between split-screen display and superimposed display can be achieved through a simple user operation, and the display mode of the display screen can be quickly switched according to user requirements, which improves interaction efficiency.
作为第一方面的一实现方式,所述在所述第二应用的显示界面显示所述翻译结果之后,还包括:As an implementation manner of the first aspect, after displaying the translation result on the display interface of the second application, the method further includes:
当接收到用户输入的更新所述第一应用当前显示内容的第二操作后,响应于所述第二操作,在所述第一应用的显示界面显示更新后的显示内容,并在所述第二应用的显示界面显示所述更新后的显示内容对应的翻译结果。After receiving a second operation input by the user to update the current display content of the first application, in response to the second operation, display the updated display content on the display interface of the first application, and display the updated display content in the first application. The display interface of the second application displays the translation result corresponding to the updated display content.
在第一方面的一实现方式中,第二应用自动根据第一应用更新的显示内容,同步更新翻译结果,不需要用户操作,提高了翻译效率。In an implementation manner of the first aspect, the second application automatically updates the translation result synchronously according to the display content updated by the first application, which does not require user operation, thereby improving translation efficiency.
作为第一方面的一实现方式,所述在所述第二应用的显示界面显示所述翻译结果之后,还包括:As an implementation manner of the first aspect, after displaying the translation result on the display interface of the second application, the method further includes:
接收用户输入的刷新翻译操作;Receive a refresh translation operation entered by the user;
响应于所述刷新翻译操作,在所述第二应用的显示界面,显示所述第一应用的显示界面当前显示内容的翻译结果。In response to the refreshing translation operation, a translation result of the content currently displayed on the display interface of the first application is displayed on the display interface of the second application.
在第一方面的一实现方式中,第二应用响应于用户操作,根据第一应用更新的显示内容,同步更新翻译结果,使得本申请实施例适用更多场景。In an implementation manner of the first aspect, the second application synchronously updates the translation result according to the display content updated by the first application in response to the user operation, so that the embodiment of the present application is applicable to more scenarios.
作为第一方面的一实现方式,所述在所述第二应用的显示界面显示所述翻译结果之后,还包括:As an implementation manner of the first aspect, after displaying the translation result on the display interface of the second application, the method further includes:
接收用户在所述第一应用中输入的第二操作;receiving a second operation input by the user in the first application;
响应于所述第二操作,若在所述第一应用的显示界面更新了显示内容,则在所述第二应用的显示界面显示更新后的显示内容对应的翻译结果。In response to the second operation, if the display content is updated on the display interface of the first application, a translation result corresponding to the updated display content is displayed on the display interface of the second application.
在第一方面的一实现方式中,自动根据第一应用中的用户操作,在确认第一应用的显示内容更新的情况下,同步更新翻译结果,不需要用户在第二应用中输入用户操作,提高了翻译效率。In an implementation manner of the first aspect, automatically according to the user operation in the first application, in the case of confirming that the display content of the first application is updated, the translation result is updated synchronously, and the user does not need to input a user operation in the second application, Improved translation efficiency.
作为第一方面的一实现方式,所述第一应用为非翻译应用。As an implementation manner of the first aspect, the first application is a non-translation application.
第二方面,对应于第一方面提供的一种翻译结果显示方法,本申请实施例还提供了一种翻译结果显示装置,包括:In the second aspect, corresponding to the translation result display method provided in the first aspect, an embodiment of the present application further provides a translation result display device, including:
第一显示模块,用于响应于用户在第一应用中输入的第一操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上,所述第二应用为翻译应用;a first display module, configured to display the display interface of the first application and the display interface of the second application in a split screen in response to a first operation input by the user in the first application; or, display the second application The display interface is superimposed and displayed on the display interface of the first application, and the second application is a translation application;
翻译模块,用于将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果;a translation module for translating the current display content in the first application into a target language to obtain a translation result;
第二显示模块,用于在所述第二应用的显示界面显示所述翻译结果。The second display module is configured to display the translation result on the display interface of the second application.
作为第二方面的一实现方式,所述第一显示模块,具体用于:As an implementation manner of the second aspect, the first display module is specifically used for:
响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;In response to the first operation input by the user in the first application, a system pop-up box is triggered, and the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若接收到用户针对所述系统弹框输入的确认操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上。If the user's confirmation operation for the system pop-up box input is received, the display interface of the first application and the display interface of the second application are displayed in a split screen; or, the display interface of the second application is superimposed and displayed on the on the display interface of the first application.
作为第二方面的一实现方式,还包括,语言获取模块,用于:As an implementation manner of the second aspect, the method further includes a language acquisition module, configured to:
获取用户在所述第二应用中输入的源语言和/或目标语言。Obtain the source language and/or target language input by the user in the second application.
在第二方面的一实现方式中,在分屏显示所述第一应用的显示界面和所述第二应用的显示界面的情形下,所述装置还包括第一切换模块,所述第一切换模块用于:In an implementation manner of the second aspect, in a case where the display interface of the first application and the display interface of the second application are displayed in a split screen, the apparatus further includes a first switching module, the first switching module Modules are used to:
响应于用户在所述第一应用的显示界面或所述第二应用的显示界面输入的第四操作,所述第一应用的显示界面或所述第二应用的显示界面切换为悬浮窗。In response to a fourth operation input by the user on the display interface of the first application or the display interface of the second application, the display interface of the first application or the display interface of the second application is switched to a floating window.
在第二方面的一实现方式中,在将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上的情形下,所述装置还包括第二切换模块,所述第二切换模块用于:In an implementation manner of the second aspect, when the display interface of the second application is superimposed and displayed on the display interface of the first application, the apparatus further includes a second switching module, the second Toggle modules are used to:
响应于用户在所述第二应用的显示界面输入的第五操作,所述第一应用的显示界面和所述第二应用的显示界面切换为分屏显示。In response to a fifth operation input by the user on the display interface of the second application, the display interface of the first application and the display interface of the second application are switched to split-screen display.
作为第二方面的一实现方式,所述装置还包括第一翻译更新模块,所述第一翻译更新模块用于:As an implementation manner of the second aspect, the device further includes a first translation update module, where the first translation update module is configured to:
当接收到用户输入的更新所述第一应用当前显示内容的第二操作后,响应于所述第二操作,在所述第一应用的显示界面显示更新后的显示内容,并在所述第二应用的显示界面显示所述更新后的显示内容对应的翻译结果。After receiving a second operation input by the user to update the current display content of the first application, in response to the second operation, display the updated display content on the display interface of the first application, and display the updated display content in the first application. The display interface of the second application displays the translation result corresponding to the updated display content.
作为第二方面的一实现方式,所述装置还包括第二翻译更新模块,所述第二翻译更新模块用于:As an implementation manner of the second aspect, the apparatus further includes a second translation update module, which is used for:
接收用户输入的刷新翻译操作;Receive a refresh translation operation entered by the user;
响应于所述刷新翻译操作,在所述第二应用的显示界面,显示所述第一应用的显示界面当前显示内容的翻译结果。In response to the refreshing translation operation, a translation result of the content currently displayed on the display interface of the first application is displayed on the display interface of the second application.
作为第二方面的一实现方式,所述装置还包括第三翻译更新模块,所述第三翻译更新模块用于:As an implementation manner of the second aspect, the device further includes a third translation update module, the third translation update module is used for:
接收用户在所述第一应用中输入的第二操作;receiving a second operation input by the user in the first application;
响应于所述第二操作,若在所述第一应用的显示界面更新了显示内容,则在所述第二应用的显示界面显示更新后的显示内容对应的翻译结果。In response to the second operation, if the display content is updated on the display interface of the first application, a translation result corresponding to the updated display content is displayed on the display interface of the second application.
可以理解的是,上述第二方面的有益效果可以参见上述第一方面中的相关描述。It can be understood that, for the beneficial effects of the foregoing second aspect, reference may be made to the relevant descriptions in the foregoing first aspect.
第三方面,本申请实施例提供了一种翻译结果显示方法,包括:In a third aspect, the embodiments of the present application provide a method for displaying translation results, including:
第一电子设备响应于用户在第一应用中输入的第一操作,将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果;The first electronic device, in response to the first operation input by the user in the first application, translates the currently displayed content in the first application into the target language, and obtains a translation result;
所述第一电子设备将所述翻译结果发送给与所述第一电子设备通信连接的第二电子设备进行显示。The first electronic device sends the translation result to a second electronic device communicatively connected to the first electronic device for display.
在第三方面的实施例中,通过简单的用户操作就能够在第二电子设备显示第一电子设备上第一应用当前显示内容的翻译结果,一方面,减小了交互成本,提高了效率;另一方面,极大地使用了不同设备的显示能力,提高了阅读效率。In the embodiment of the third aspect, the translation result of the content currently displayed by the first application on the first electronic device can be displayed on the second electronic device through a simple user operation. On the one hand, the interaction cost is reduced and the efficiency is improved; On the other hand, the display capabilities of different devices are greatly used, and the reading efficiency is improved.
作为第三方面的一实现方式,所述第一电子设备响应于用户在第一应用中输入的第一操作,将 所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果,包括:As an implementation manner of the third aspect, the first electronic device, in response to a first operation input by the user in the first application, translates the content currently displayed in the first application into a target language, and obtains a translation result, including :
第一电子设备响应于用户在第一应用中输入的第一操作,显示设备列表;The first electronic device displays a device list in response to a first operation input by the user in the first application;
所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
作为第三方面的一实现方式,所述第一电子设备响应于用户在第一应用中输入的第一操作,将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果,包括:As an implementation manner of the third aspect, the first electronic device, in response to a first operation input by the user in the first application, translates the content currently displayed in the first application into a target language, and obtains a translation result, including :
第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,建立与第二电子设备之间的通信连接;If the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
作为第三方面的一实现方式,所述第一电子设备响应于用户在第一应用中输入的第一操作,将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果,包括:As an implementation manner of the third aspect, the first electronic device, in response to a first operation input by the user in the first application, translates the content currently displayed in the first application into a target language, and obtains a translation result, including :
第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,显示设备列表;If the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list;
所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
作为第三方面的一实现方式,所述方法还包括:As an implementation manner of the third aspect, the method further includes:
所述第一电子设备接收到用户输入的更新所述第一应用当前显示内容的第二操作;receiving, by the first electronic device, a second operation input by the user for updating the content currently displayed by the first application;
所述第一电子设备响应于所述第二操作,在所述第一应用的显示界面显示更新后的显示内容,指示所述第二电子设备显示所述更新后的显示内容对应的翻译结果。The first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
在第三方面的一实现方式中,第一电子设备根据第一应用更新的显示内容,指示第二电子设备同步更新翻译结果,不需要用户输入特定操作,提高了翻译效率。In an implementation manner of the third aspect, the first electronic device instructs the second electronic device to update the translation result synchronously according to the display content updated by the first application, without requiring the user to input a specific operation, thereby improving translation efficiency.
作为第三方面的一实现方式,所述方法还包括:As an implementation manner of the third aspect, the method further includes:
所述第一电子设备接收到用户输入的刷新翻译操作;The first electronic device receives a refresh translation operation input by the user;
所述第一电子设备响应于所述刷新翻译操作,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果;The first electronic device, in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
或,所述方法还包括:Or, the method further includes:
所述第一电子设备接收到来自第二电子设备的刷新翻译指示;所述刷新翻译指示由所述第二电子设备接收到用户输入的刷新翻译操作而触发;The first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
所述第一电子设备响应于所述刷新翻译指示,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果。The first electronic device, in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
在第三方面的一实现方式中,第一电子设备或第二电子设备根据用户输入的特定操作,实现第一电子设备指示第二电子设备同步更新翻译结果,提高了翻译效率。In an implementation manner of the third aspect, the first electronic device or the second electronic device implements the first electronic device to instruct the second electronic device to update the translation result synchronously according to a specific operation input by the user, thereby improving translation efficiency.
作为第三方面的一实现方式,所述方法还包括:As an implementation manner of the third aspect, the method further includes:
所述第一电子设备接收到用户在所述第一应用中输入的第二操作;the first electronic device receives a second operation input by the user in the first application;
所述第一电子设备响应于所述第二操作,若确定所述第一应用的显示界面更新了显示内容,则指示所述第二电子设备显示所述第一应用更新后的显示内容对应的翻译结果。In response to the second operation, the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
在第三方面的一实现方式中,第一电子设备响应于接收到的用户操作,若确定更新了显示内容,指示第二电子设备同步更新翻译结果,提高了翻译效率。In an implementation of the third aspect, in response to the received user operation, if it is determined that the display content is updated, the first electronic device instructs the second electronic device to update the translation result synchronously, thereby improving translation efficiency.
第四方面,对应于第三方面提供的一种翻译结果显示方法,本申请实施例还提供了一种翻译结果显示装置,包括:In the fourth aspect, corresponding to a translation result display method provided in the third aspect, an embodiment of the present application further provides a translation result display device, including:
翻译模块,用于第一电子设备响应于用户在第一应用中输入的第一操作,将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果;a translation module, used for the first electronic device to translate the currently displayed content in the first application into a target language in response to a first operation input by the user in the first application, and obtain a translation result;
发送模块,用于所述第一电子设备将所述翻译结果发送给与所述第一电子设备通信连接的第二电子设备进行显示。A sending module is used for the first electronic device to send the translation result to a second electronic device communicatively connected to the first electronic device for display.
作为第四方面的一实现方式,所述翻译模块,具体用于:As an implementation manner of the fourth aspect, the translation module is specifically used for:
第一电子设备响应于用户在第一应用中输入的第一操作,显示设备列表;The first electronic device displays a device list in response to a first operation input by the user in the first application;
所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
作为第四方面的一实现方式,所述翻译模块,具体用于:As an implementation manner of the fourth aspect, the translation module is specifically used for:
第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,建立与第二电子设备之间的通信连接;If the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
作为第四方面的一实现方式,所述所述翻译模块,具体用于:As an implementation manner of the fourth aspect, the translation module is specifically used for:
第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,显示设备列表;If the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list;
所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
作为第四方面的一实现方式,所述装置还包括第一翻译更新模块,所述第一翻译更新模块用于:As an implementation manner of the fourth aspect, the device further includes a first translation update module, where the first translation update module is configured to:
所述第一电子设备接收到用户输入的更新所述第一应用当前显示内容的第二操作;receiving, by the first electronic device, a second operation input by the user for updating the content currently displayed by the first application;
所述第一电子设备响应于所述第二操作,在所述第一应用的显示界面显示更新后的显示内容,指示所述第二电子设备显示所述更新后的显示内容对应的翻译结果。The first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
作为第四方面的一实现方式,所述装置还包括第二翻译更新模块,As an implementation manner of the fourth aspect, the device further includes a second translation update module,
所述第二翻译更新模块用于:The second translation update module is used for:
所述第一电子设备接收到用户输入的刷新翻译操作;The first electronic device receives a refresh translation operation input by the user;
所述第一电子设备响应于所述刷新翻译操作,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果;The first electronic device, in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
或,所述第二翻译更新模块用于:Or, the second translation update module is used for:
所述第一电子设备接收到来自第二电子设备的刷新翻译指示;所述刷新翻译指示由所述第二电 子设备接收到用户输入的刷新翻译操作而触发;The first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
所述第一电子设备响应于所述刷新翻译指示,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果。The first electronic device, in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
作为第四方面的一实现方式,所述装置还包括第三翻译更新模块,所述第三翻译更新模块用于:As an implementation manner of the fourth aspect, the device further includes a third translation update module, which is used for:
所述第一电子设备接收到用户在所述第一应用中输入的第二操作;the first electronic device receives a second operation input by the user in the first application;
所述第一电子设备响应于所述第二操作,若确定所述第一应用的显示界面更新了显示内容,则指示所述第二电子设备显示所述第一应用更新后的显示内容对应的翻译结果。In response to the second operation, the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
可以理解的是,上述第四方面的有益效果可以参见上述第三方面中的相关描述。It can be understood that, for the beneficial effects of the foregoing fourth aspect, reference may be made to the relevant descriptions in the foregoing third aspect.
第五方面,本申请实施例提供了一种翻译结果显示方法,包括:In a fifth aspect, the embodiments of the present application provide a method for displaying translation results, including:
第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容;The first electronic device, in response to a first operation input by the user in the first application, acquires the currently displayed content in the first application;
所述第一电子设备将所述当前显示内容发送给与所述第一电子设备通信连接的第二电子设备,并指示所述第二电子设备将所述显示内容翻译成目标语言后进行显示。The first electronic device sends the currently displayed content to a second electronic device that is communicatively connected to the first electronic device, and instructs the second electronic device to translate the displayed content into a target language before displaying it.
在第五方面的实施例中,通过简单的用户操作就能够在第二电子设备显示第一电子设备上第一应用当前显示内容的翻译结果,一方面,减小了交互成本,提高了效率;另一方面,极大地使用了不同设备的显示能力,提高了阅读效率。In the embodiment of the fifth aspect, the translation result of the content currently displayed by the first application on the first electronic device can be displayed on the second electronic device through a simple user operation. On the one hand, the interaction cost is reduced and the efficiency is improved; On the other hand, the display capabilities of different devices are greatly used, and the reading efficiency is improved.
作为第五方面的一实现方式,所述第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容,包括:As an implementation manner of the fifth aspect, in response to a first operation input by a user in the first application, the first electronic device acquires the current display content in the first application, including:
第一电子设备响应于用户在第一应用中输入的第一操作,显示设备列表;The first electronic device displays a device list in response to a first operation input by the user in the first application;
所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires the currently displayed content in the first application.
作为第五方面的一实现方式,所述第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容,包括:As an implementation manner of the fifth aspect, the first electronic device, in response to a first operation input by the user in the first application, acquires the currently displayed content in the first application, including:
第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,建立与第二电子设备之间的通信连接;If the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires the currently displayed content in the first application.
作为第五方面的一实现方式,所述第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容,包括:As an implementation manner of the fifth aspect, the first electronic device, in response to a first operation input by the user in the first application, acquires the currently displayed content in the first application, including:
第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,显示设备列表;If the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list;
所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires the currently displayed content in the first application.
作为第五方面的一实现方式,所述方法还包括:As an implementation manner of the fifth aspect, the method further includes:
所述第一电子设备接收到用户输入的更新所述第一应用当前显示内容的第二操作;receiving, by the first electronic device, a second operation input by the user for updating the content currently displayed by the first application;
所述第一电子设备响应于所述第二操作,在所述第一应用的显示界面显示更新后的显示内容, 指示所述第二电子设备显示所述更新后的显示内容对应的翻译结果。The first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
在第五方面的一实现方式中,第一电子设备根据第一应用更新的显示内容,指示第二电子设备同步更新翻译结果,不需要用户输入特定操作,提高了翻译效率。In an implementation manner of the fifth aspect, the first electronic device instructs the second electronic device to update the translation result synchronously according to the display content updated by the first application, without requiring the user to input a specific operation, thereby improving translation efficiency.
作为第五方面的一实现方式,所述方法还包括:As an implementation manner of the fifth aspect, the method further includes:
所述第一电子设备接收到用户输入的刷新翻译操作;The first electronic device receives a refresh translation operation input by the user;
所述第一电子设备响应于所述刷新翻译操作,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果;The first electronic device, in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
或,所述方法还包括:Or, the method further includes:
所述第一电子设备接收到来自第二电子设备的刷新翻译指示;所述刷新翻译指示由所述第二电子设备接收到用户输入的刷新翻译操作而触发;The first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
所述第一电子设备响应于所述刷新翻译指示,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果。The first electronic device, in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
在第五方面的一实现方式中,第一电子设备或第二电子设备根据用户输入的特定操作,实现第一电子设备指示第二电子设备同步更新翻译结果,提高了翻译效率。In an implementation manner of the fifth aspect, the first electronic device or the second electronic device realizes that the first electronic device instructs the second electronic device to update the translation result synchronously according to a specific operation input by the user, thereby improving translation efficiency.
作为第五方面的一实现方式,所述方法还包括:As an implementation manner of the fifth aspect, the method further includes:
所述第一电子设备接收到用户在所述第一应用中输入的第二操作;the first electronic device receives a second operation input by the user in the first application;
所述第一电子设备响应于所述第二操作,若确定所述第一应用的显示界面更新了显示内容,则指示所述第二电子设备显示所述第一应用更新后的显示内容对应的翻译结果。In response to the second operation, the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
在第五方面的一实现方式中,第一电子设备响应于接收到的用户操作,若确定更新了显示内容,指示第二电子设备同步更新翻译结果,提高了翻译效率。In an implementation manner of the fifth aspect, in response to the received user operation, if it is determined that the displayed content is updated, the first electronic device instructs the second electronic device to update the translation result synchronously, thereby improving translation efficiency.
第六方面,对应于第五方面提供的一种翻译结果显示方法,本申请实施例还提供了一种翻译结果显示装置,包括:In the sixth aspect, corresponding to a translation result display method provided in the fifth aspect, an embodiment of the present application further provides a translation result display device, including:
获取模块,用于第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容;an obtaining module, used for the first electronic device to obtain the currently displayed content in the first application in response to the first operation input by the user in the first application;
发送模块,用于所述第一电子设备将所述当前显示内容发送给与所述第一电子设备通信连接的第二电子设备,并指示所述第二电子设备将所述显示内容翻译成目标语言后进行显示。a sending module, used for the first electronic device to send the currently displayed content to a second electronic device that is communicatively connected to the first electronic device, and instruct the second electronic device to translate the displayed content into a target displayed after the language.
作为第六方面的一实现方式,所述获取模块,具体用于:As an implementation manner of the sixth aspect, the acquisition module is specifically used for:
第一电子设备响应于用户在第一应用中输入的第一操作,显示设备列表;The first electronic device displays a device list in response to a first operation input by the user in the first application;
所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires the currently displayed content in the first application.
作为第六方面的一实现方式,所述获取模块,具体用于:As an implementation manner of the sixth aspect, the acquisition module is specifically used for:
第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,建立与第二电子设备之间的通信连接;If the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires the currently displayed content in the first application.
作为第六方面的一实现方式,所述获取模块,具体用于:As an implementation manner of the sixth aspect, the acquisition module is specifically used for:
第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询 问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, and the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,显示设备列表;If the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list;
所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires the currently displayed content in the first application.
作为第六方面的一实现方式,所述装置还包括第一翻译更新模块,所述第一翻译更新模块用于:As an implementation manner of the sixth aspect, the device further includes a first translation update module, where the first translation update module is configured to:
所述第一电子设备接收到用户输入的更新所述第一应用当前显示内容的第二操作;receiving, by the first electronic device, a second operation input by the user for updating the content currently displayed by the first application;
所述第一电子设备响应于所述第二操作,在所述第一应用的显示界面显示更新后的显示内容,指示所述第二电子设备显示所述更新后的显示内容对应的翻译结果。The first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
作为第六方面的一实现方式,所述装置还包括第二翻译更新模块,所述第二翻译更新模块用于:As an implementation manner of the sixth aspect, the apparatus further includes a second translation update module, which is used for:
所述第一电子设备接收到用户输入的刷新翻译操作;The first electronic device receives a refresh translation operation input by the user;
所述第一电子设备响应于所述刷新翻译操作,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果;The first electronic device, in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
或,所述第二翻译更新模块用于:Or, the second translation update module is used for:
所述第一电子设备接收到来自第二电子设备的刷新翻译指示;所述刷新翻译指示由所述第二电子设备接收到用户输入的刷新翻译操作而触发;The first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
所述第一电子设备响应于所述刷新翻译指示,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果。The first electronic device, in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
作为第六方面的一实现方式,所述装置还包括第三翻译更新模块,所述第三翻译更新模块用于:As an implementation manner of the sixth aspect, the device further includes a third translation update module, which is used for:
所述第一电子设备接收到用户在所述第一应用中输入的第二操作;the first electronic device receives a second operation input by the user in the first application;
所述第一电子设备响应于所述第二操作,若确定所述第一应用的显示界面更新了显示内容,则指示所述第二电子设备显示所述第一应用更新后的显示内容对应的翻译结果。In response to the second operation, the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
可以理解的是,上述第六方面的有益效果可以参见上述第五方面中的相关描述。It can be understood that, for the beneficial effects of the above sixth aspect, reference may be made to the relevant description in the above fifth aspect.
第七方面,本申请实施例提供了一种电子设备,包括显示屏、存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时,使得所述电子设备实现如第一方面和第一方面可能的实现方式中任一所述的方法,或,实现如第三方面和第三方面可能的实现方式中任一所述的方法,或,实现如第五方面和第五方面可能的实现方式中任一所述的方法。In a seventh aspect, an embodiment of the present application provides an electronic device, including a display screen, a memory, a processor, and a computer program stored in the memory and executable on the processor, the processor executing the In the case of a computer program, the electronic device is made to implement the method described in any one of the first aspect and the possible implementation manner of the first aspect, or implement the method described in any one of the third aspect and the possible implementation manner of the third aspect The method, or, implement the method according to any one of the fifth aspect and the possible implementation manner of the fifth aspect.
第八方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现如第一方面和第一方面可能的实现方式中任一所述的方法,或,实现如第三方面和第三方面可能的实现方式中任一所述的方法,或,实现如第五方面和第五方面可能的实现方式中任一所述的方法。In an eighth aspect, an embodiment of the present application provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the first aspect and the first aspect are possible Implement the method described in any one of the implementation manners, or, implement the method described in any one of the third aspect and the possible implementation manner of the third aspect, or implement any of the possible implementation manners of the fifth aspect and the fifth aspect. a described method.
第九方面,本申请实施例提供了一种计算机程序产品,当计算机程序产品在电子设备上运行时,使得电子设备执行上述第一方面和第一方面可能的实现方式中任一所述的方法,或,执行上述第三方面和第三方面可能的实现方式中任一所述的方法,或,执行上述第五方面和第五方面可能的实现方式中任一所述的方法。In a ninth aspect, an embodiment of the present application provides a computer program product that, when the computer program product runs on an electronic device, enables the electronic device to execute the method described in any one of the first aspect and the possible implementations of the first aspect , or, perform the method described in any one of the third aspect and possible implementation manners of the third aspect, or perform the method described in any one of the foregoing fifth aspect and possible implementation manners of the fifth aspect.
可以理解的是,上述第七方面至第九方面的有益效果可以参见上述第一方面、第三方面和第五方面中的相关描述。It can be understood that, for the beneficial effects of the seventh aspect to the ninth aspect, reference may be made to the relevant descriptions in the first aspect, the third aspect and the fifth aspect.
附图说明Description of drawings
图1是本申请一实施例提供的翻译结果显示方法所适用于的手机的硬件结构示意图;1 is a schematic diagram of the hardware structure of a mobile phone to which a translation result display method provided by an embodiment of the present application is applicable;
图2A是本申请一实施例提供的翻译结果显示方法所适用于的手机的软件结构示意图;2A is a schematic diagram of a software structure of a mobile phone to which the translation result display method provided by an embodiment of the present application is applicable;
图2B是本申请一实施例提供的翻译结果显示方法所适用于的手机的软件结构示意图;2B is a schematic diagram of a software structure of a mobile phone to which the translation result display method provided by an embodiment of the present application is applicable;
图3A是本申请一实施例提供的翻译结果显示方法的流程示意图;3A is a schematic flowchart of a translation result display method provided by an embodiment of the present application;
图3B是本申请一实施例提供的在阅读APP的显示界面触发系统弹框的示意图;3B is a schematic diagram of triggering a system pop-up frame on a display interface of a reading APP provided by an embodiment of the present application;
图3C是本申请一实施例提供的阅读APP和翻译APP分屏显示的示意图;3C is a schematic diagram of split-screen display of a reading APP and a translation APP provided by an embodiment of the present application;
图3D是本申请另一实施例提供的阅读APP和翻译APP分屏显示的示例图;3D is an example diagram of split-screen display of a reading APP and a translation APP provided by another embodiment of the present application;
图3E是本申请一实施例提供的在翻译APP的显示界面输入源语言和目标语言的示例图;3E is an example diagram of inputting a source language and a target language on a display interface of a translation APP provided by an embodiment of the present application;
图3F是本申请一实施例提供的阅读APP和翻译APP分屏显示阅读内容和翻译结果的示意图;3F is a schematic diagram of a reading APP and a translation APP provided by an embodiment of the present application to display reading content and translation results on a split screen;
图3G是本申请另一实施例提供的阅读APP和翻译APP分屏显示阅读内容和翻译结果的示意图;3G is a schematic diagram of a reading APP and a translation APP provided by another embodiment of the present application to display reading content and translation results in split screens;
图4A是本申请一实施例提供的翻译APP显示翻译结果的流程示意图;4A is a schematic flowchart of a translation APP displaying translation results provided by an embodiment of the present application;
图4B是本申请一实施例提供的获取阅读APP显示截图的示意图;4B is a schematic diagram of obtaining a screenshot of a reading APP display provided by an embodiment of the present application;
图5A是本申请一实施例提供的用户确认进入分屏翻译界面的示意图;5A is a schematic diagram of a user confirming entry into a split-screen translation interface provided by an embodiment of the present application;
图5B是本申请一实施例提供的翻译APP叠加显示在阅读APP上的示意图;5B is a schematic diagram of a translation APP provided by an embodiment of the present application being superimposed and displayed on a reading APP;
图5C是本申请一实施例提供的从悬浮窗切换到分屏显示的示意图;5C is a schematic diagram of switching from a floating window to a split-screen display provided by an embodiment of the present application;
图5D是本申请另一实施例提供的从悬浮窗切换到分屏显示的示意图;5D is a schematic diagram of switching from a floating window to a split-screen display provided by another embodiment of the present application;
图5E是本申请一实施例提供的从分屏显示切换到悬浮窗的示意图;5E is a schematic diagram of switching from a split-screen display to a floating window provided by an embodiment of the present application;
图5F是本申请另一实施例提供的从分屏显示切换到悬浮窗的示意图;5F is a schematic diagram of switching from split-screen display to a floating window provided by another embodiment of the present application;
图5G是本申请另一实施例提供的从分屏显示切换到悬浮窗的示意图;5G is a schematic diagram of switching from split-screen display to a floating window provided by another embodiment of the present application;
图5H是本申请另一实施例提供的从分屏显示切换到悬浮窗的示意图;5H is a schematic diagram of switching from split-screen display to a floating window provided by another embodiment of the present application;
图6A是本申请另一实施例提供的翻译结果显示方法的流程示意图;6A is a schematic flowchart of a translation result display method provided by another embodiment of the present application;
图6B是本申请一实施例提供的翻译APP自动同步显示阅读APP更新后的显示内容对应的翻译结果的示意图;6B is a schematic diagram of the translation result corresponding to the updated display content of the reading APP displayed automatically and synchronously by the translation APP provided by an embodiment of the present application;
图7A是本申请另一实施例提供的翻译结果显示方法的流程示意图;7A is a schematic flowchart of a translation result display method provided by another embodiment of the present application;
图7B是本申请一实施例提供的通过用户手动操作,实现翻译APP同步显示阅读APP更新后的显示内容对应的翻译结果的示意图;7B is a schematic diagram of a translation result corresponding to the updated display content of the reading APP being synchronously displayed by the translation APP through manual operation by the user according to an embodiment of the present application;
图8是本申请另一实施例提供的翻译结果显示方法的流程示意图;8 is a schematic flowchart of a translation result display method provided by another embodiment of the present application;
图9A是本申请另一实施例提供的翻译结果显示方法的流程示意图;9A is a schematic flowchart of a translation result display method provided by another embodiment of the present application;
图9B是本申请另一实施例提供的翻译结果显示方法的过程示意图。FIG. 9B is a schematic process diagram of a translation result display method provided by another embodiment of the present application.
具体实施方式detailed description
以下描述中,为了说明而不是为了限定,提出了诸如特定系统结构、技术之类的具体细节,以便透彻理解本申请实施例。然而,本领域的技术人员应当清楚,在没有这些具体细节的其它实施例中也可以实现本申请。在其它情况中,省略对众所周知的系统、装置、电路以及方法的详细说明,以免不必要的细节妨碍本申请的描述。In the following description, for the purpose of illustration rather than limitation, specific details such as a specific system structure and technology are set forth in order to provide a thorough understanding of the embodiments of the present application. However, it will be apparent to those skilled in the art that the present application may be practiced in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
以下实施例中所使用的术语只是为了描述特定实施例的目的,而并非旨在作为对本申请的限制。如在本申请的说明书和所附权利要求书中所使用的那样,单数表达形式“一个”、“一种”、“所述”、“上述”、“该”和“这一”旨在也包括例如“一个或多个”这种表达形式,除非其上下文中明确地有相反指示。The terms used in the following embodiments are for the purpose of describing particular embodiments only, and are not intended to be limitations of the present application. As used in the specification of this application and the appended claims, the singular expressions "a," "an," "the," "above," "the," and "the" are intended to also Expressions such as "one or more" are included unless the context clearly dictates otherwise.
还应当理解,在本申请实施例中,“一个或多个”和“若干个”是指一个、两个或两个以上; “和/或”,描述关联对象的关联关系,表示可以存在三种关系;例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B的情况,其中A、B可以是单数或者复数。字符“/”一般表示前后关联对象是一种“或”的关系。It should also be understood that, in the embodiments of the present application, "one or more" and "several" refer to one, two or more than two; A relationship; for example, A and/or B, can represent: the existence of A alone, the existence of A and B at the same time, and the existence of B alone, where A and B can be singular or plural. The character "/" generally indicates that the associated objects are an "or" relationship.
当在本申请说明书和所附权利要求书中使用时,术语“包括”指示所描述特征、整体、步骤、操作、元素和/或组件的存在,但并不排除一个或多个其它特征、整体、步骤、操作、元素、组件和/或其集合的存在或添加。When used in this specification and the appended claims, the term "comprising" indicates the presence of the described feature, integer, step, operation, element and/or component, but does not exclude one or more other features, integers , step, operation, element, component and/or the presence or addition of a collection thereof.
如在本申请说明书和所附权利要求书中所使用的那样,术语“若”可以依据上下文被解释为“当...时”或“一旦”或“响应于确定”或“响应于检测到”。As used in the specification of this application and the appended claims, the term "if" may be interpreted, depending on the context, as "when" or "once" or "in response to determining" or "in response to detecting ".
另外,在本申请说明书和所附权利要求书的描述中,术语“第一”、“第二”、“第三”等仅用于区分描述,而不能理解为指示或暗示相对重要性。In addition, in the description of the specification of the present application and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the description, and should not be construed as indicating or implying relative importance.
在本申请说明书中描述的参考“一实施例”或“一些实施例”等意味着在本申请的一个或多个实施例中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中的不同之处出现的语句“在一些实施例中”、“在其他一些实施例中”、“在另外一些实施例中”等不是必然都参考相同的实施例,而是意味着“一个或多个但不是所有的实施例”,除非是以其他方式另外特别强调。术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。References in this specification to "one embodiment" or "some embodiments" and the like mean that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in some embodiments," "in other embodiments," "in other embodiments," etc. in various places in this specification are not necessarily all referring to the same embodiment, but rather is meant to mean "one or more but not all embodiments" unless specifically emphasized otherwise. The terms "including", "including", "having" and their variants mean "including but not limited to" unless specifically emphasized otherwise.
为了说明本申请的技术方案,下面通过具体实施例来进行说明。In order to illustrate the technical solutions of the present application, the following specific embodiments are used for description.
目前,当遭遇阅读障碍时,用户需要进行复杂的操作以切换到翻译界面,并且,需要在翻译界面手动输入待查询内容以获得翻译结果。操作繁琐,效率低下。如果用户要进行大量翻译时,翻译效率非常低,将大大降低用户体验。At present, when encountering dyslexia, users need to perform complex operations to switch to the translation interface, and need to manually input the content to be queried in the translation interface to obtain translation results. The operation is cumbersome and inefficient. If the user needs to do a lot of translation, the translation efficiency is very low, which will greatly reduce the user experience.
本申请考虑到现有技术方案的不足,提供了一种翻译结果显示方法。本申请实施例提供的翻译结果显示方法,一方面,通过简单的用户操作就可以显示翻译结果,简化了用户操作,提升了效率;另一方面,将阅读内容(或待翻译内容)和翻译结果同时显示,在一个屏幕显示更多的信息,提高了多任务交互的效率。In consideration of the deficiencies of the prior art solutions, the present application provides a method for displaying translation results. The translation result display method provided by the embodiment of the present application, on the one hand, the translation result can be displayed through a simple user operation, which simplifies the user operation and improves the efficiency; Simultaneous display, displaying more information on one screen, improves the efficiency of multi-task interaction.
本申请实施例提供的翻译结果显示方法,适用于用户通过电子设备阅读时需要翻译的情形。所述翻译结果显示方法应用于电子设备,可由配置于电子设备的翻译结果显示装置执行。所述翻译结果显示装置可由电子设备的软件、硬件、或软件和硬件的组合实现。The translation result display method provided by the embodiment of the present application is suitable for the situation that a user needs to translate when reading through an electronic device. The translation result display method is applied to an electronic device, and can be executed by a translation result display device configured in the electronic device. The translation result display device may be implemented by software, hardware, or a combination of software and hardware of an electronic device.
本申请实施例提供的翻译结果显示方法可以应用于手机、平板电脑、可穿戴设备、车载设备(或称车机)、增强现实(augmented reality,AR)/虚拟现实(virtual reality,VR)设备、笔记本电脑、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本、个人数字助理(personal digital assistant,PDA)、智慧屏、电视、智能音响等电子设备,本申请实施例对电子设备的具体类型不作任何限制。The translation result display method provided by the embodiments of the present application can be applied to mobile phones, tablet computers, wearable devices, in-vehicle devices (or vehicle machines), augmented reality (AR)/virtual reality (VR) devices, Electronic devices such as notebook computers, ultra-mobile personal computers (UMPCs), netbooks, personal digital assistants (PDAs), smart screens, TVs, and smart speakers. Type does not impose any restrictions.
图1示出了电子设备100的结构示意图。FIG. 1 shows a schematic structural diagram of an electronic device 100 .
电子设备100可以包括处理器110,外部存储器接口120,内部存储器121,通用串行总线(universal serial bus,USB)接口130,充电管理模块140,电源管理模块141,电池142,天线1,天线2,移动通信模块150,无线通信模块160,音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,传感器模块180,按键190,马达191,指示器192,摄像头193,显示屏194,以及用户标识模块(subscriber identification module,SIM)卡接口195等。其中传感器模块180可以包括压力传感器180A,陀螺仪传感器180B,气压传感器180C,磁传感器180D,加速度传感器180E,距离 传感器180F,接近光传感器180G,指纹传感器180H,温度传感器180J,触摸传感器180K,环境光传感器180L,骨传导传感器180M等。The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charge management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2 , mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headphone jack 170D, sensor module 180, buttons 190, motor 191, indicator 192, camera 193, display screen 194, and Subscriber identification module (subscriber identification module, SIM) card interface 195 and so on. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, and ambient light. Sensor 180L, bone conduction sensor 180M, etc.
可以理解的是,本发明实施例示意的结构并不构成对电子设备100的具体限定。在本申请另一些实施例中,电子设备100可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件或软件和硬件的组合实现。It can be understood that, the structures illustrated in the embodiments of the present invention do not constitute a specific limitation on the electronic device 100 . In other embodiments of the present application, the electronic device 100 may include more or less components than shown, or combine some components, or separate some components, or arrange different components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
处理器110可以包括一个或多个处理单元,例如:处理器110可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processing unit,GPU),图像信号处理器(image signal processor,ISP),控制器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), controller, video codec, digital signal processor (digital signal processor, DSP), baseband processor, and/or neural-network processing unit (neural-network processing unit, NPU), etc. Wherein, different processing units may be independent devices, or may be integrated in one or more processors.
控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。The controller can generate an operation control signal according to the instruction operation code and timing signal, and complete the control of fetching and executing instructions.
处理器110中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器110中的存储器为高速缓冲存储器。该存储器可以保存处理器110刚用过或循环使用的指令或数据。如果处理器110需要再次使用该指令或数据,可从所述存储器中直接调用。避免了重复存取,减少了处理器110的等待时间,因而提高了系统的效率。A memory may also be provided in the processor 110 for storing instructions and data. In some embodiments, the memory in processor 110 is cache memory. This memory may hold instructions or data that have just been used or recycled by the processor 110 . If the processor 110 needs to use the instruction or data again, it can be called directly from the memory. Repeated accesses are avoided and the latency of the processor 110 is reduced, thereby increasing the efficiency of the system.
在一些实施例中,处理器110可以包括一个或多个接口。接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integrated circuit sound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purpose input/output,GPIO)接口,用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。In some embodiments, the processor 110 may include one or more interfaces. The interface may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous transceiver (universal asynchronous transmitter) receiver/transmitter, UART) interface, mobile industry processor interface (MIPI), general-purpose input/output (GPIO) interface, subscriber identity module (SIM) interface, and / or universal serial bus (universal serial bus, USB) interface, etc.
I2C接口是一种双向同步串行总线,包括一根串行数据线(serial data line,SDA)和一根串行时钟线(derail clock line,SCL)。在一些实施例中,处理器110可以包含多组I2C总线。处理器110可以通过不同的I2C总线接口分别耦合触摸传感器180K,充电器,闪光灯,摄像头193等。例如:处理器110可以通过I2C接口耦合触摸传感器180K,使处理器110与触摸传感器180K通过I2C总线接口通信,实现电子设备100的触摸功能。The I2C interface is a bidirectional synchronous serial bus that includes a serial data line (SDA) and a serial clock line (SCL). In some embodiments, the processor 110 may contain multiple sets of I2C buses. The processor 110 can be respectively coupled to the touch sensor 180K, the charger, the flash, the camera 193 and the like through different I2C bus interfaces. For example, the processor 110 may couple the touch sensor 180K through the I2C interface, so that the processor 110 and the touch sensor 180K communicate with each other through the I2C bus interface, so as to realize the touch function of the electronic device 100 .
I2S接口可以用于音频通信。在一些实施例中,处理器110可以包含多组I2S总线。处理器110可以通过I2S总线与音频模块170耦合,实现处理器110与音频模块170之间的通信。在一些实施例中,音频模块170可以通过I2S接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。The I2S interface can be used for audio communication. In some embodiments, the processor 110 may contain multiple sets of I2S buses. The processor 110 may be coupled with the audio module 170 through an I2S bus to implement communication between the processor 110 and the audio module 170 . In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 through the I2S interface, so as to realize the function of answering calls through a Bluetooth headset.
PCM接口也可以用于音频通信,将模拟信号抽样,量化和编码。在一些实施例中,音频模块170与无线通信模块160可以通过PCM总线接口耦合。在一些实施例中,音频模块170也可以通过PCM接口向无线通信模块160传递音频信号,实现通过蓝牙耳机接听电话的功能。所述I2S接口和所述PCM接口都可以用于音频通信。The PCM interface can also be used for audio communications, sampling, quantizing and encoding analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 may be coupled through a PCM bus interface. In some embodiments, the audio module 170 can also transmit audio signals to the wireless communication module 160 through the PCM interface, so as to realize the function of answering calls through the Bluetooth headset. Both the I2S interface and the PCM interface can be used for audio communication.
UART接口是一种通用串行数据总线,用于异步通信。该总线可以为双向通信总线。它将要传输的数据在串行通信与并行通信之间转换。在一些实施例中,UART接口通常被用于连接处理器110与无线通信模块160。例如:处理器110通过UART接口与无线通信模块160中的蓝牙模块通信,实现蓝牙功能。在一些实施例中,音频模块170可以通过UART接口向无线通信模块160传递音频信号,实现通过蓝牙耳机播放音乐的功能。The UART interface is a universal serial data bus used for asynchronous communication. The bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, a UART interface is typically used to connect the processor 110 with the wireless communication module 160 . For example, the processor 110 communicates with the Bluetooth module in the wireless communication module 160 through the UART interface to implement the Bluetooth function. In some embodiments, the audio module 170 can transmit audio signals to the wireless communication module 160 through the UART interface, so as to realize the function of playing music through the Bluetooth headset.
MIPI接口可以被用于连接处理器110与显示屏194,摄像头193等外围器件。MIPI接口包括摄像头串行接口(camera serial interface,CSI),显示屏串行接口(display serial interface,DSI)等。在一些实施例中,处理器110和摄像头193通过CSI接口通信,实现电子设备100的拍摄功能。处理器110和显示屏194通过DSI接口通信,实现电子设备100的显示功能。The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193 . MIPI interfaces include camera serial interface (CSI), display serial interface (DSI), etc. In some embodiments, the processor 110 communicates with the camera 193 through a CSI interface, so as to realize the photographing function of the electronic device 100 . The processor 110 communicates with the display screen 194 through the DSI interface to implement the display function of the electronic device 100 .
GPIO接口可以通过软件配置。GPIO接口可以被配置为控制信号,也可被配置为数据信号。在一些实施例中,GPIO接口可以用于连接处理器110与摄像头193,显示屏194,无线通信模块160,音频模块170,传感器模块180等。GPIO接口还可以被配置为I2C接口,I2S接口,UART接口,MIPI接口等。The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface may be used to connect the processor 110 with the camera 193, the display screen 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like. The GPIO interface can also be configured as I2C interface, I2S interface, UART interface, MIPI interface, etc.
USB接口130是符合USB标准规范的接口,具体可以是Mini USB接口,Micro USB接口,USB Type C接口等。USB接口130可以用于连接充电器为电子设备100充电,也可以用于电子设备100与外围设备之间传输数据。也可以用于连接耳机,通过耳机播放音频。该接口还可以用于连接其他电子设备,例如AR设备等。The USB interface 130 is an interface that conforms to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, and the like. The USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transmit data between the electronic device 100 and peripheral devices. It can also be used to connect headphones to play audio through the headphones. The interface can also be used to connect other electronic devices, such as AR devices.
可以理解的是,本发明实施例示意的各模块间的接口连接关系,只是示意性说明,并不构成对电子设备100的结构限定。在本申请另一些实施例中,电子设备100也可以采用上述实施例中不同的接口连接方式,或多种接口连接方式的组合。It can be understood that the interface connection relationship between the modules illustrated in the embodiment of the present invention is only a schematic illustration, and does not constitute a structural limitation of the electronic device 100 . In other embodiments of the present application, the electronic device 100 may also adopt different interface connection manners in the foregoing embodiments, or a combination of multiple interface connection manners.
充电管理模块140用于从充电器接收充电输入。其中,充电器可以是无线充电器,也可以是有线充电器。在一些有线充电的实施例中,充电管理模块140可以通过USB接口130接收有线充电器的充电输入。在一些无线充电的实施例中,充电管理模块140可以通过电子设备100的无线充电线圈接收无线充电输入。充电管理模块140为电池142充电的同时,还可以通过电源管理模块141为电子设备供电。The charging management module 140 is used to receive charging input from the charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from the wired charger through the USB interface 130 . In some wireless charging embodiments, the charging management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100 . While the charging management module 140 charges the battery 142 , it can also supply power to the electronic device through the power management module 141 .
电源管理模块141用于连接电池142,充电管理模块140与处理器110。电源管理模块141接收电池142和/或充电管理模块140的输入,为处理器110,内部存储器121,显示屏194,摄像头193,和无线通信模块160等供电。电源管理模块141还可以用于监测电池容量,电池循环次数,电池健康状态(漏电,阻抗)等参数。在其他一些实施例中,电源管理模块141也可以设置于处理器110中。在另一些实施例中,电源管理模块141和充电管理模块140也可以设置于同一个器件中。The power management module 141 is used for connecting the battery 142 , the charging management module 140 and the processor 110 . The power management module 141 receives the input from the battery 142 and/or the charging management module 140 and supplies power to the processor 110 , the internal memory 121 , the display screen 194 , the camera 193 , and the wireless communication module 160 . The power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle times, battery health status (leakage, impedance). In some other embodiments, the power management module 141 may also be provided in the processor 110 . In other embodiments, the power management module 141 and the charging management module 140 may also be provided in the same device.
电子设备100的无线通信功能可以通过天线1,天线2,移动通信模块150,无线通信模块160,调制解调处理器以及基带处理器等实现。The wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modulation and demodulation processor, the baseband processor, and the like.
天线1和天线2用于发射和接收电磁波信号。电子设备100中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。例如:可以将天线1复用为无线局域网的分集天线。在另外一些实施例中,天线可以和调谐开关结合使用。Antenna 1 and Antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 may be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve antenna utilization. For example, the antenna 1 can be multiplexed as a diversity antenna of the wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
移动通信模块150可以提供应用在电子设备100上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块150可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(low noise amplifier,LNA)等。移动通信模块150可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块150还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块150的至少部分功能模块可以被设置于处理器110中。在一些实施例中,移动通信模块150的至少部分功能模块可以与处理器110的至少部分模块被设置在同一个器件中。The mobile communication module 150 may provide wireless communication solutions including 2G/3G/4G/5G etc. applied on the electronic device 100 . The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (LNA) and the like. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, filter and amplify the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and then turn it into an electromagnetic wave for radiation through the antenna 1 . In some embodiments, at least part of the functional modules of the mobile communication module 150 may be provided in the processor 110 . In some embodiments, at least part of the functional modules of the mobile communication module 150 may be provided in the same device as at least part of the modules of the processor 110 .
调制解调处理器可以包括调制器和解调器。其中,调制器用于将待发送的低频基带信号调制成中高频信号。解调器用于将接收的电磁波信号解调为低频基带信号。随后解调器将解调得到的低频 基带信号传送至基带处理器处理。低频基带信号经基带处理器处理后,被传递给应用处理器。应用处理器通过音频设备(不限于扬声器170A,受话器170B等)输出声音信号,或通过显示屏194显示图像或视频。在一些实施例中,调制解调处理器可以是独立的器件。在另一些实施例中,调制解调处理器可以独立于处理器110,与移动通信模块150或其他功能模块设置在同一个器件中。The modem processor may include a modulator and a demodulator. Wherein, the modulator is used to modulate the low frequency baseband signal to be sent into a medium and high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. The low frequency baseband signal is processed by the baseband processor and passed to the application processor. The application processor outputs sound signals through audio devices (not limited to the speaker 170A, the receiver 170B, etc.), or displays images or videos through the display screen 194 . In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be independent of the processor 110, and may be provided in the same device as the mobile communication module 150 or other functional modules.
无线通信模块160可以提供应用在电子设备100上的包括无线局域网(wireless local area networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequency modulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块160可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块160经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器110。无线通信模块160还可以从处理器110接收待发送的信号,对其进行调频,放大,经天线2转为电磁波辐射出去。The wireless communication module 160 can provide applications on the electronic device 100 including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellites System (global navigation satellite system, GNSS), frequency modulation (frequency modulation, FM), near field communication technology (near field communication, NFC), infrared technology (infrared, IR) and other wireless communication solutions. The wireless communication module 160 may be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2 , frequency modulates and filters the electromagnetic wave signals, and sends the processed signals to the processor 110 . The wireless communication module 160 can also receive the signal to be sent from the processor 110 , perform frequency modulation on it, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2 .
在一些实施例中,电子设备100的天线1和移动通信模块150耦合,天线2和无线通信模块160耦合,使得电子设备100可以通过无线通信技术与网络以及其他设备通信。所述无线通信技术可以包括全球移动通讯系统(global system for mobile communications,GSM),通用分组无线服务(general packet radio service,GPRS),码分多址接入(code division multiple access,CDMA),宽带码分多址(wideband code division multiple access,WCDMA),时分码分多址(time-division code division multiple access,TD-SCDMA),长期演进(long term evolution,LTE),BT,GNSS,WLAN,NFC,FM,和/或IR技术等。所述GNSS可以包括全球卫星定位系统(global positioning system,GPS),全球导航卫星系统(global navigation satellite system,GLONASS),北斗卫星导航系统(beidou navigation satellite system,BDS),准天顶卫星系统(quasi-zenith satellite system,QZSS)和/或星基增强系统(satellite based augmentation systems,SBAS)。In some embodiments, the antenna 1 of the electronic device 100 is coupled with the mobile communication module 150, and the antenna 2 is coupled with the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology. The wireless communication technologies may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), broadband Code Division Multiple Access (WCDMA), Time Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC , FM, and/or IR technology, etc. The GNSS may include a global positioning system (global positioning system, GPS), a global navigation satellite system (GLONASS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (quasi -zenith satellite system, QZSS) and/or satellite based augmentation systems (SBAS).
电子设备100通过GPU,显示屏194,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏194和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器110可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。The electronic device 100 implements a display function through a GPU, a display screen 194, an application processor, and the like. The GPU is a microprocessor for image processing, and is connected to the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.
显示屏194用于显示图像,视频等。显示屏194包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emitting diode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrix organic light emitting diode的,AMOLED),柔性发光二极管(flex light-emitting diode,FLED),Miniled,MicroLed,Micro-oLed,量子点发光二极管(quantum dot light emitting diodes,QLED)等。在一些实施例中,电子设备100可以包括1个或N个显示屏194,N为大于1的正整数。Display screen 194 is used to display images, videos, and the like. Display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (active-matrix organic light). emitting diode, AMOLED), flexible light-emitting diode (flex light-emitting diode, FLED), Miniled, MicroLed, Micro-oLed, quantum dot light-emitting diode (quantum dot light emitting diodes, QLED) and so on. In some embodiments, the electronic device 100 may include one or N display screens 194 , where N is a positive integer greater than one.
电子设备100可以通过ISP,摄像头193,视频编解码器,GPU,显示屏194以及应用处理器等实现拍摄功能。The electronic device 100 may implement a shooting function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
ISP用于处理摄像头193反馈的数据。例如,拍照时,打开快门,光线通过镜头被传递到摄像头感光元件上,光信号转换为电信号,摄像头感光元件将所述电信号传递给ISP处理,转化为肉眼可见的图像。ISP还可以对图像的噪点,亮度,肤色进行算法优化。ISP还可以对拍摄场景的曝光,色温等参数优化。在一些实施例中,ISP可以设置在摄像头193中。The ISP is used to process the data fed back by the camera 193 . For example, when taking a photo, the shutter is opened, the light is transmitted to the camera photosensitive element through the lens, the light signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, and converts it into an image visible to the naked eye. ISP can also perform algorithm optimization on image noise, brightness, and skin tone. ISP can also optimize the exposure, color temperature and other parameters of the shooting scene. In some embodiments, the ISP may be provided in the camera 193 .
摄像头193用于捕获静态图像或视频。物体通过镜头生成光学图像投射到感光元件。感光元件可以是电荷耦合器件(charge coupled device,CCD)或互补金属氧化物半导体(complementary metal-oxide-semiconductor,CMOS)光电晶体管。感光元件把光信号转换成电信号,之后将电信号传 递给ISP转换成数字图像信号。ISP将数字图像信号输出到DSP加工处理。DSP将数字图像信号转换成标准的RGB,YUV等格式的图像信号。在一些实施例中,电子设备100可以包括1个或N个摄像头193,N为大于1的正整数。Camera 193 is used to capture still images or video. The object is projected through the lens to generate an optical image onto the photosensitive element. The photosensitive element may be a charge coupled device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, and then transmits the electrical signal to the ISP to convert it into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. DSP converts digital image signals into standard RGB, YUV and other formats of image signals. In some embodiments, the electronic device 100 may include 1 or N cameras 193 , where N is a positive integer greater than 1.
数字信号处理器用于处理数字信号,除了可以处理数字图像信号,还可以处理其他数字信号。例如,当电子设备100在频点选择时,数字信号处理器用于对频点能量进行傅里叶变换等。A digital signal processor is used to process digital signals, in addition to processing digital image signals, it can also process other digital signals. For example, when the electronic device 100 selects a frequency point, the digital signal processor is used to perform Fourier transform on the frequency point energy and so on.
视频编解码器用于对数字视频压缩或解压缩。电子设备100可以支持一种或多种视频编解码器。这样,电子设备100可以播放或录制多种编码格式的视频,例如:动态图像专家组(moving picture experts group,MPEG)1,MPEG2,MPEG3,MPEG4等。Video codecs are used to compress or decompress digital video. The electronic device 100 may support one or more video codecs. In this way, the electronic device 100 can play or record videos of various encoding formats, such as: Moving Picture Experts Group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4 and so on.
NPU为神经网络(neural-network,NN)计算处理器,通过借鉴生物神经网络结构,例如借鉴人脑神经元之间传递模式,对输入信息快速处理,还可以不断的自学习。通过NPU可以实现电子设备100的智能认知等应用,例如:图像识别,人脸识别,语音识别,文本理解等。The NPU is a neural-network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transfer mode between neurons in the human brain, it can quickly process the input information, and can continuously learn by itself. Applications such as intelligent cognition of the electronic device 100 can be implemented through the NPU, such as image recognition, face recognition, speech recognition, text understanding, and the like.
外部存储器接口120可以用于连接外部存储卡,例如Micro SD卡,实现扩展电子设备100的存储能力。外部存储卡通过外部存储器接口120与处理器110通信,实现数据存储功能。例如将音乐,视频等文件保存在外部存储卡中。The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100 . The external memory card communicates with the processor 110 through the external memory interface 120 to realize the data storage function. For example to save files like music, video etc in external memory card.
内部存储器121可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储电子设备100使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。处理器110通过运行存储在内部存储器121的指令,和/或存储在设置于处理器中的存储器的指令,执行电子设备100的各种功能应用以及数据处理。Internal memory 121 may be used to store computer executable program code, which includes instructions. The internal memory 121 may include a storage program area and a storage data area. The storage program area can store an operating system, an application program required for at least one function (such as a sound playback function, an image playback function, etc.), and the like. The storage data area may store data (such as audio data, phone book, etc.) created during the use of the electronic device 100 and the like. In addition, the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, universal flash storage (UFS), and the like. The processor 110 executes various functional applications and data processing of the electronic device 100 by executing instructions stored in the internal memory 121 and/or instructions stored in a memory provided in the processor.
电子设备100可以通过音频模块170,扬声器170A,受话器170B,麦克风170C,耳机接口170D,以及应用处理器等实现音频功能。例如音乐播放,录音等。The electronic device 100 may implement audio functions through an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, an application processor, and the like. Such as music playback, recording, etc.
音频模块170用于将数字音频信息转换成模拟音频信号输出,也用于将模拟音频输入转换为数字音频信号。音频模块170还可以用于对音频信号编码和解码。在一些实施例中,音频模块170可以设置于处理器110中,或将音频模块170的部分功能模块设置于处理器110中。The audio module 170 is used for converting digital audio information into analog audio signal output, and also for converting analog audio input into digital audio signal. Audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be provided in the processor 110 , or some functional modules of the audio module 170 may be provided in the processor 110 .
扬声器170A,也称“喇叭”,用于将音频电信号转换为声音信号。电子设备100可以通过扬声器170A收听音乐,或收听免提通话。 Speaker 170A, also referred to as a "speaker", is used to convert audio electrical signals into sound signals. The electronic device 100 can listen to music through the speaker 170A, or listen to a hands-free call.
受话器170B,也称“听筒”,用于将音频电信号转换成声音信号。当电子设备100接听电话或语音信息时,可以通过将受话器170B靠近人耳接听语音。The receiver 170B, also referred to as "earpiece", is used to convert audio electrical signals into sound signals. When the electronic device 100 answers a call or a voice message, the voice can be answered by placing the receiver 170B close to the human ear.
麦克风170C,也称“话筒”,“传声器”,用于将声音信号转换为电信号。当拨打电话或发送语音信息时,用户可以通过人嘴靠近麦克风170C发声,将声音信号输入到麦克风170C。电子设备100可以设置至少一个麦克风170C。在另一些实施例中,电子设备100可以设置两个麦克风170C,除了采集声音信号,还可以实现降噪功能。在另一些实施例中,电子设备100还可以设置三个,四个或更多麦克风170C,实现采集声音信号,降噪,还可以识别声音来源,实现定向录音功能等。The microphone 170C, also called "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or sending a voice message, the user can make a sound by approaching the microphone 170C through a human mouth, and input the sound signal into the microphone 170C. The electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C, which can implement a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further be provided with three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and implement directional recording functions.
耳机接口170D用于连接有线耳机。耳机接口170D可以是USB接口130,也可以是3.5mm的开放移动电子设备平台(open mobile terminal platform,OMTP)标准接口,美国蜂窝电信工业协会(cellular telecommunications industry association of the USA,CTIA)标准接口。The earphone jack 170D is used to connect wired earphones. The earphone interface 170D can be the USB interface 130, or can be a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.
压力传感器180A用于感受压力信号,可以将压力信号转换成电信号。在一些实施例中,压力传 感器180A可以设置于显示屏194。压力传感器180A的种类很多,如电阻式压力传感器,电感式压力传感器,电容式压力传感器等。电容式压力传感器可以是包括至少两个具有导电材料的平行板。当有力作用于压力传感器180A,电极之间的电容改变。电子设备100根据电容的变化确定压力的强度。当有触摸操作作用于显示屏194,电子设备100根据压力传感器180A检测所述触摸操作强度。电子设备100也可以根据压力传感器180A的检测信号计算触摸的位置。在一些实施例中,作用于相同触摸位置,但不同触摸操作强度的触摸操作,可以对应不同的操作指令。例如:当有触摸操作强度小于第一压力阈值的触摸操作作用于短消息应用图标时,执行查看短消息的指令。当有触摸操作强度大于或等于第一压力阈值的触摸操作作用于短消息应用图标时,执行新建短消息的指令。The pressure sensor 180A is used to sense pressure signals, and can convert the pressure signals into electrical signals. In some embodiments, pressure sensor 180A may be provided on display screen 194. There are many types of pressure sensors 180A, such as resistive pressure sensors, inductive pressure sensors, capacitive pressure sensors, and the like. The capacitive pressure sensor may be comprised of at least two parallel plates of conductive material. When a force is applied to the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the intensity of the pressure according to the change in capacitance. When a touch operation acts on the display screen 194, the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A. The electronic device 100 may also calculate the touched position according to the detection signal of the pressure sensor 180A. In some embodiments, touch operations acting on the same touch position but with different touch operation intensities may correspond to different operation instructions. For example, when a touch operation whose intensity is less than the first pressure threshold acts on the short message application icon, the instruction for viewing the short message is executed. When a touch operation with a touch operation intensity greater than or equal to the first pressure threshold acts on the short message application icon, the instruction to create a new short message is executed.
陀螺仪传感器180B可以用于确定电子设备100的运动姿态。在一些实施例中,可以通过陀螺仪传感器180B确定电子设备100围绕三个轴(即,x,y和z轴)的角速度。陀螺仪传感器180B可以用于拍摄防抖。示例性的,当按下快门,陀螺仪传感器180B检测电子设备100抖动的角度,根据角度计算出镜头模组需要补偿的距离,让镜头通过反向运动抵消电子设备100的抖动,实现防抖。陀螺仪传感器180B还可以用于导航,体感游戏场景。The gyro sensor 180B may be used to determine the motion attitude of the electronic device 100 . In some embodiments, the angular velocity of electronic device 100 about three axes (ie, x, y, and z axes) may be determined by gyro sensor 180B. The gyro sensor 180B can be used for image stabilization. Exemplarily, when the shutter is pressed, the gyro sensor 180B detects the shaking angle of the electronic device 100, calculates the distance that the lens module needs to compensate according to the angle, and allows the lens to offset the shaking of the electronic device 100 through reverse motion to achieve anti-shake. The gyro sensor 180B can also be used for navigation and somatosensory game scenarios.
气压传感器180C用于测量气压。在一些实施例中,电子设备100通过气压传感器180C测得的气压值计算海拔高度,辅助定位和导航。The air pressure sensor 180C is used to measure air pressure. In some embodiments, the electronic device 100 calculates the altitude through the air pressure value measured by the air pressure sensor 180C to assist in positioning and navigation.
磁传感器180D包括霍尔传感器。电子设备100可以利用磁传感器180D检测翻盖皮套的开合。在一些实施例中,当电子设备100是翻盖机时,电子设备100可以根据磁传感器180D检测翻盖的开合。进而根据检测到的皮套的开合状态或翻盖的开合状态,设置翻盖自动解锁等特性。The magnetic sensor 180D includes a Hall sensor. The electronic device 100 can detect the opening and closing of the flip holster using the magnetic sensor 180D. In some embodiments, when the electronic device 100 is a flip machine, the electronic device 100 can detect the opening and closing of the flip according to the magnetic sensor 180D. Further, according to the detected opening and closing state of the leather case or the opening and closing state of the flip cover, characteristics such as automatic unlocking of the flip cover are set.
加速度传感器180E可检测电子设备100在各个方向上(一般为三轴)加速度的大小。当电子设备100静止时可检测出重力的大小及方向。还可以用于识别电子设备姿态,应用于横竖屏切换,计步器等应用。The acceleration sensor 180E can detect the magnitude of the acceleration of the electronic device 100 in various directions (generally three axes). The magnitude and direction of gravity can be detected when the electronic device 100 is stationary. It can also be used to identify the posture of electronic devices, and can be used in applications such as horizontal and vertical screen switching, pedometers, etc.
距离传感器180F,用于测量距离。电子设备100可以通过红外或激光测量距离。在一些实施例中,拍摄场景,电子设备100可以利用距离传感器180F测距以实现快速对焦。Distance sensor 180F for measuring distance. The electronic device 100 can measure the distance through infrared or laser. In some embodiments, when shooting a scene, the electronic device 100 can use the distance sensor 180F to measure the distance to achieve fast focusing.
接近光传感器180G可以包括例如发光二极管(LED)和光检测器,例如光电二极管。发光二极管可以是红外发光二极管。电子设备100通过发光二极管向外发射红外光。电子设备100使用光电二极管检测来自附近物体的红外反射光。当检测到充分的反射光时,可以确定电子设备100附近有物体。当检测到不充分的反射光时,电子设备100可以确定电子设备100附近没有物体。电子设备100可以利用接近光传感器180G检测用户手持电子设备100贴近耳朵通话,以便自动熄灭屏幕达到省电的目的。接近光传感器180G也可用于皮套模式,口袋模式自动解锁与锁屏。Proximity light sensor 180G may include, for example, light emitting diodes (LEDs) and light detectors, such as photodiodes. The light emitting diodes may be infrared light emitting diodes. The electronic device 100 emits infrared light to the outside through the light emitting diode. Electronic device 100 uses photodiodes to detect infrared reflected light from nearby objects. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100 . When insufficient reflected light is detected, the electronic device 100 may determine that there is no object near the electronic device 100 . The electronic device 100 can use the proximity light sensor 180G to detect that the user holds the electronic device 100 close to the ear to talk, so as to automatically turn off the screen to save power. Proximity light sensor 180G can also be used in holster mode, pocket mode automatically unlocks and locks the screen.
环境光传感器180L用于感知环境光亮度。电子设备100可以根据感知的环境光亮度自适应调节显示屏194亮度。环境光传感器180L也可用于拍照时自动调节白平衡。环境光传感器180L还可以与接近光传感器180G配合,检测电子设备100是否在口袋里,以防误触。The ambient light sensor 180L is used to sense ambient light brightness. The electronic device 100 can adaptively adjust the brightness of the display screen 194 according to the perceived ambient light brightness. The ambient light sensor 180L can also be used to automatically adjust the white balance when taking pictures. The ambient light sensor 180L can also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket, so as to prevent accidental touch.
指纹传感器180H用于采集指纹。电子设备100可以利用采集的指纹特性实现指纹解锁,访问应用锁,指纹拍照,指纹接听来电等。The fingerprint sensor 180H is used to collect fingerprints. The electronic device 100 can use the collected fingerprint characteristics to realize fingerprint unlocking, accessing application locks, taking pictures with fingerprints, answering incoming calls with fingerprints, and the like.
温度传感器180J用于检测温度。在一些实施例中,电子设备100利用温度传感器180J检测的温度,执行温度处理策略。例如,当温度传感器180J上报的温度超过阈值,电子设备100执行降低位于温度传感器180J附近的处理器的性能,以便降低功耗实施热保护。在另一些实施例中,当温度低于另一阈值时,电子设备100对电池142加热,以避免低温导致电子设备100异常关机。在其他一些实施例中,当温度低于又一阈值时,电子设备100对电池142的输出电压执行升压,以避免低温 导致的异常关机。The temperature sensor 180J is used to detect the temperature. In some embodiments, the electronic device 100 uses the temperature detected by the temperature sensor 180J to execute a temperature processing strategy. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold value, the electronic device 100 reduces the performance of the processor located near the temperature sensor 180J in order to reduce power consumption and implement thermal protection. In other embodiments, when the temperature is lower than another threshold, the electronic device 100 heats the battery 142 to avoid abnormal shutdown of the electronic device 100 caused by the low temperature. In some other embodiments, when the temperature is lower than yet another threshold, the electronic device 100 performs a boost to the output voltage of the battery 142 to avoid abnormal shutdown caused by low temperature.
触摸传感器180K,也称“触控器件”。触摸传感器180K可以设置于显示屏194,由触摸传感器180K与显示屏194组成触摸屏,也称“触控屏”。触摸传感器180K用于检测作用于其上或附近的触摸操作。触摸传感器可以将检测到的触摸操作传递给应用处理器,以确定触摸事件类型。可以通过显示屏194提供与触摸操作相关的视觉输出。在另一些实施例中,触摸传感器180K也可以设置于电子设备100的表面,与显示屏194所处的位置不同。Touch sensor 180K, also called "touch device". The touch sensor 180K may be disposed on the display screen 194 , and the touch sensor 180K and the display screen 194 form a touch screen, also called a “touch screen”. The touch sensor 180K is used to detect a touch operation on or near it. The touch sensor can pass the detected touch operation to the application processor to determine the type of touch event. Visual output related to touch operations may be provided through display screen 194 . In other embodiments, the touch sensor 180K may also be disposed on the surface of the electronic device 100 , which is different from the location where the display screen 194 is located.
骨传导传感器180M可以获取振动信号。在一些实施例中,骨传导传感器180M可以获取人体声部振动骨块的振动信号。骨传导传感器180M也可以接触人体脉搏,接收血压跳动信号。在一些实施例中,骨传导传感器180M也可以设置于耳机中,结合成骨传导耳机。音频模块170可以基于所述骨传导传感器180M获取的声部振动骨块的振动信号,解析出语音信号,实现语音功能。应用处理器可以基于所述骨传导传感器180M获取的血压跳动信号解析心率信息,实现心率检测功能。The bone conduction sensor 180M can acquire vibration signals. In some embodiments, the bone conduction sensor 180M can acquire the vibration signal of the vibrating bone mass of the human voice. The bone conduction sensor 180M can also contact the pulse of the human body and receive the blood pressure beating signal. In some embodiments, the bone conduction sensor 180M can also be disposed in the earphone, combined with the bone conduction earphone. The audio module 170 can analyze the voice signal based on the vibration signal of the vocal vibration bone block obtained by the bone conduction sensor 180M, so as to realize the voice function. The application processor can analyze the heart rate information based on the blood pressure beat signal obtained by the bone conduction sensor 180M, and realize the function of heart rate detection.
按键190包括开机键,音量键等。按键190可以是机械按键。也可以是触摸式按键。电子设备100可以接收按键输入,产生与电子设备100的用户设置以及功能控制有关的键信号输入。The keys 190 include a power-on key, a volume key, and the like. Keys 190 may be mechanical keys. It can also be a touch key. The electronic device 100 may receive key inputs and generate key signal inputs related to user settings and function control of the electronic device 100 .
马达191可以产生振动提示。马达191可以用于来电振动提示,也可以用于触摸振动反馈。例如,作用于不同应用(例如拍照,音频播放等)的触摸操作,可以对应不同的振动反馈效果。作用于显示屏194不同区域的触摸操作,马达191也可对应不同的振动反馈效果。不同的应用场景(例如:时间提醒,接收信息,闹钟,游戏等)也可以对应不同的振动反馈效果。触摸振动反馈效果还可以支持自定义。Motor 191 can generate vibrating cues. The motor 191 can be used for vibrating alerts for incoming calls, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, playing audio, etc.) can correspond to different vibration feedback effects. The motor 191 can also correspond to different vibration feedback effects for touch operations on different areas of the display screen 194 . Different application scenarios (for example: time reminder, receiving information, alarm clock, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization.
指示器192可以是指示灯,可以用于指示充电状态,电量变化,也可以用于指示消息,未接来电,通知等。The indicator 192 can be an indicator light, which can be used to indicate the charging state, the change of the power, and can also be used to indicate a message, a missed call, a notification, and the like.
SIM卡接口195用于连接SIM卡。SIM卡可以通过插入SIM卡接口195,或从SIM卡接口195拔出,实现和电子设备100的接触和分离。电子设备100可以支持1个或N个SIM卡接口,N为大于1的正整数。SIM卡接口195可以支持Nano SIM卡,Micro SIM卡,SIM卡等。同一个SIM卡接口195可以同时插入多张卡。所述多张卡的类型可以相同,也可以不同。SIM卡接口195也可以兼容不同类型的SIM卡。SIM卡接口195也可以兼容外部存储卡。电子设备100通过SIM卡和网络交互,实现通话以及数据通信等功能。在一些实施例中,电子设备100采用eSIM,即:嵌入式SIM卡。eSIM卡可以嵌在电子设备100中,不能和电子设备100分离。The SIM card interface 195 is used to connect a SIM card. The SIM card can be contacted and separated from the electronic device 100 by inserting into the SIM card interface 195 or pulling out from the SIM card interface 195 . The electronic device 100 may support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM card, Micro SIM card, SIM card and so on. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the plurality of cards may be the same or different. The SIM card interface 195 can also be compatible with different types of SIM cards. The SIM card interface 195 is also compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to implement functions such as call and data communication. In some embodiments, the electronic device 100 employs an eSIM, ie: an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100 .
电子设备100的软件系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。本发明实施例以分层架构的安卓(Android)系统为例,示例性说明电子设备100的软件结构。The software system of the electronic device 100 may adopt a layered architecture, an event-driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture. The embodiment of the present invention takes an Android system with a layered architecture as an example to illustrate the software structure of the electronic device 100 as an example.
图2A是本发明实施例提供的翻译结果显示方法所适用于的电子设备100的软件结构框图。FIG. 2A is a block diagram of a software structure of an electronic device 100 to which the translation result display method provided by an embodiment of the present invention is applied.
分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将Android系统分为四层,从上至下分别为应用程序层,应用程序框架层,安卓运行时(Android runtime)和系统库,以及内核层。The layered architecture divides the software into several layers, and each layer has a clear role and division of labor. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, which are, from top to bottom, an application layer, an application framework layer, an Android runtime (Android runtime) and a system library, and a kernel layer.
应用程序层可以包括一系列应用程序包。The application layer can include a series of application packages.
如图2A所示,应用程序包可以包括相机,图库,阅读,翻译,办公软件(例如WPS Office),短信息、浏览器等应用程序。As shown in FIG. 2A, the application package may include camera, gallery, reading, translation, office software (eg WPS Office), short message, browser and other applications.
应用程序框架层为应用程序层的应用程序提供应用编程接口(application programming interface,API)和编程框架。应用程序框架层包括一些预先定义的函数。The application framework layer provides an application programming interface (application programming interface, API) and a programming framework for applications in the application layer. The application framework layer includes some predefined functions.
如图2A所示,应用程序框架层可以包括输入事件管理器,窗口管理器,内容提供器,视图系统, 电话管理器,资源管理器,通知管理器等。As shown in FIG. 2A, the application framework layer may include an input event manager, a window manager, a content provider, a view system, a telephony manager, a resource manager, a notification manager, and the like.
输入事件管理器,用于监听各种触摸操作事件。在本申请实施例中,输入事件管理器可以包括手势监听模块和滑动事件监听模块。手势事件监听模块可以用于进行手势监听,例如三指捏合,或点击特定控件等手势。滑动事件监听模块可以用于进行滑动事件监听,例如滑动翻页的触摸操作等。输入事件管理器的手势监听模块监听到手势事件,触发询问用户是否进入分屏翻译界面的系统弹框。输入事件管理器向翻译APP提供滑动事件监听,用于触发翻译APP刷新翻译内容。Input event manager for listening to various touch operation events. In this embodiment of the present application, the input event manager may include a gesture monitoring module and a sliding event monitoring module. The gesture event monitoring module can be used to monitor gestures, such as three-finger pinch, or gestures such as clicking on a specific control. The sliding event monitoring module can be used to monitor sliding events, such as the touch operation of sliding pages. The gesture monitoring module of the input event manager listens to the gesture event and triggers a system pop-up box that asks the user whether to enter the split-screen translation interface. The input event manager provides sliding event monitoring to the translation APP, which is used to trigger the translation APP to refresh the translation content.
窗口管理器用于管理窗口程序。在Android应用框架中,窗口可以包括应用窗口和公共界面的窗口(即系统级别的窗口)。窗口管理器可以获取显示屏大小,判断是否有状态栏,锁定屏幕,截取屏幕等。在本申请一些实施例中,窗口管理器可以包括应用分屏窗口管理器,应用分屏窗口管理器可以包括:分屏管理,窗口截图和系统弹窗等模块。系统弹窗模块可以用于启动系统弹框,系统弹框可以为询问用户是否进入分屏翻译界面的系统弹框。输入事件管理器的手势监听模块监听到手势事件,调用系统弹窗模块以启动询问用户是否进入分屏翻译界面的系统弹框。A window manager is used to manage window programs. In the Android application framework, windows can include application windows and public interface windows (ie, system-level windows). The window manager can get the size of the display screen, determine whether there is a status bar, lock the screen, take screenshots, etc. In some embodiments of the present application, the window manager may include an application split-screen window manager, and the application split-screen window manager may include modules such as split-screen management, window screenshots, and system pop-up windows. The system popup module can be used to start the system popup, and the system popup can be a system popup that asks the user whether to enter the split-screen translation interface. The gesture monitoring module of the input event manager monitors the gesture event, and calls the system pop-up module to start the system pop-up box that asks the user whether to enter the split-screen translation interface.
内容提供器用来存放和获取数据,并使这些数据可以被应用程序访问。所述数据可以包括视频,图像,音频,拨打和接听的电话,浏览历史和书签,电话簿等。Content providers are used to store and retrieve data and make these data accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, phone book, etc.
视图系统包括可视控件,例如显示文字的控件,显示图片的控件等。视图系统可用于构建应用程序。显示界面可以由一个或多个视图组成的。例如,包括短信通知图标的显示界面,可以包括显示文字的视图以及显示图片的视图。The view system includes visual controls, such as controls for displaying text, controls for displaying pictures, and so on. View systems can be used to build applications. A display interface can consist of one or more views. For example, the display interface including the short message notification icon may include a view for displaying text and a view for displaying pictures.
电话管理器用于提供电子设备100的通信功能。例如通话状态的管理(包括接通,挂断等)。The phone manager is used to provide the communication function of the electronic device 100 . For example, the management of call status (including connecting, hanging up, etc.).
资源管理器为应用程序提供各种资源,比如本地化字符串,图标,图片,布局文件,视频文件等等。The resource manager provides various resources for the application, such as localization strings, icons, pictures, layout files, video files and so on.
通知管理器使应用程序可以在状态栏中显示通知信息,可以用于传达告知类型的消息,可以短暂停留后自动消失,无需用户交互。比如通知管理器被用于告知下载完成,消息提醒等。通知管理器还可以是以图表或者滚动条文本形式出现在系统顶部状态栏的通知,例如后台运行的应用程序的通知,还可以是以对话窗口形式出现在屏幕上的通知。例如在状态栏提示文本信息,发出提示音,电子设备振动,指示灯闪烁等。The notification manager enables applications to display notification information in the status bar, which can be used to convey notification-type messages, and can disappear automatically after a brief pause without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also display notifications in the status bar at the top of the system in the form of graphs or scroll bar text, such as notifications of applications running in the background, and notifications on the screen in the form of dialog windows. For example, text information is prompted in the status bar, a prompt sound is issued, the electronic device vibrates, and the indicator light flashes.
Android Runtime包括核心库和虚拟机。Android Runtime负责安卓系统的调度和管理。Android Runtime includes core libraries and a virtual machine. Android Runtime is responsible for scheduling and management of the Android system.
核心库包含两部分:一部分是java语言需要调用的功能函数,另一部分是安卓的核心库。The core library consists of two parts: one is the function functions that the java language needs to call, and the other is the core library of Android.
应用程序层和应用程序框架层运行在虚拟机中。虚拟机将应用程序层和应用程序框架层的java文件执行为二进制文件。虚拟机用于执行对象生命周期的管理,堆栈管理,线程管理,安全和异常的管理,以及垃圾回收等功能。The application layer and the application framework layer run in virtual machines. The virtual machine executes the java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, safety and exception management, and garbage collection.
系统库可以包括多个功能模块。例如:表面管理器(surface manager),媒体库(Media Libraries),三维(3D)图形处理库(例如:OpenGLES),二维(2D)图形引擎(例如:SGL)等。A system library can include multiple functional modules. For example: surface manager (surface manager), media library (Media Libraries), three-dimensional (3D) graphics processing library (eg: OpenGLES), two-dimensional (2D) graphics engine (eg: SGL) and so on.
表面管理器用于对显示子系统进行管理,并且为多个应用程序提供了2D和3D图层的融合。The Surface Manager is used to manage the display subsystem and provides a fusion of 2D and 3D layers for multiple applications.
媒体库支持多种常用的音频,视频格式回放和录制,以及静态图像文件等。媒体库可以支持多种音视频编码格式,例如:MPEG4,H.264,MP3,AAC,AMR,JPG,PNG等。The media library supports playback and recording of a variety of commonly used audio and video formats, as well as still image files. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.
3D图形处理库用于实现3D图形绘图,图像渲染,合成,和图层处理等。The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.
2D图形引擎是2D绘图的绘图引擎。2D graphics engine is a drawing engine for 2D drawing.
内核层是硬件和软件之间的层。内核层至少包含显示驱动,摄像头驱动,音频驱动,传感器驱动。The kernel layer is the layer between hardware and software. The kernel layer contains at least display drivers, camera drivers, audio drivers, and sensor drivers.
下面结合本申请实施例提供的翻译结果显示方法,示例性说明电子设备100软件以及硬件的工作流程。The following exemplarily describes the workflow of the software and hardware of the electronic device 100 with reference to the translation result display method provided by the embodiments of the present application.
电子设备开启了阅读APP,阅读APP为全屏模式(full screen)。当电子设备100的触摸传感器180K接收到三指捏合的触摸操作,相应的硬件中断被发给内核层。内核层将三指捏合的触摸操作加工成第一原始输入事件(包括触摸滑动坐标序列,触摸操作的起始和结束时间戳等信息),并存储第一原始输入事件。应用程序框架层从内核层获取第一原始输入事件,调用系统弹窗模块以触发系统弹框,询问用户是否进入分屏翻译界面。The reading APP is turned on on the electronic device, and the reading APP is in full screen mode. When the touch sensor 180K of the electronic device 100 receives a three-finger pinch touch operation, a corresponding hardware interrupt is sent to the kernel layer. The kernel layer processes the three-finger pinch touch operation into a first original input event (including the touch sliding coordinate sequence, the start and end timestamps of the touch operation, etc.), and stores the first original input event. The application framework layer obtains the first original input event from the kernel layer, calls the system popup module to trigger the system popup, and asks the user whether to enter the split-screen translation interface.
当电子设备100的触摸传感器180K接收到点击的触摸操作,相应的硬件中断被发给内核层。内核层将点击的触摸操作加工成第二原始输入事件(包括触摸坐标,触摸操作的时间戳等信息),并存储第二原始输入事件。应用程序框架层从内核层获取第二原始输入事件,识别该第二原始输入事件所对应的控件为系统弹框中的确认控件,例如“是”控件。阅读APP从全屏模式切换到分屏模式,显示在显示屏194的一侧;系统以分屏模式启动翻译APP,翻译APP显示在显示屏194的另一侧。When the touch sensor 180K of the electronic device 100 receives the clicked touch operation, a corresponding hardware interrupt is sent to the kernel layer. The kernel layer processes the clicked touch operation into a second original input event (including touch coordinates, time stamps of the touch operation and other information), and stores the second original input event. The application framework layer obtains the second original input event from the kernel layer, and identifies the control corresponding to the second original input event as a confirmation control in the system pop-up box, such as a "Yes" control. The reading APP is switched from the full-screen mode to the split-screen mode and displayed on one side of the display screen 194 ; the system starts the translation APP in the split-screen mode, and the translation APP is displayed on the other side of the display screen 194 .
在上述实施例中,使用了系统现有的分屏管理框架,增加了手势触发系统弹框。应用程序框架层的输入事件管理器中的手势监听模块实现手势事件监听,例如监听三指捏合的触摸操作,手势事件用于触发询问用户是否进入分屏翻译界面的系统弹框。当检测到用户点击系统弹框中的确认控件时,阅读APP切换至分屏模式,以分屏模式启动翻译APP。显示屏194的一侧显示阅读APP,一侧显示翻译APP。本示例实现了阅读内容和翻译结果分屏并行显示。In the above-mentioned embodiment, the existing split-screen management framework of the system is used, and a gesture-triggered system popup frame is added. The gesture monitoring module in the input event manager of the application framework layer implements gesture event monitoring, such as monitoring the touch operation of three-finger pinch, and the gesture event is used to trigger a system pop-up box that asks the user whether to enter the split-screen translation interface. When it is detected that the user clicks the confirmation control in the system pop-up box, the reading APP switches to the split-screen mode, and starts the translation APP in the split-screen mode. One side of the display screen 194 displays the reading APP, and the other side displays the translation APP. This example implements a split-screen parallel display of the reading content and translation results.
需要说明的是,在本申请其他一些实施例中,可以通过监听到用户点击特定控件,来触发系统弹框。特定控件可以包括阅读APP显示界面中的控件,或下拉通知栏中的控件,或悬浮球中的控件等。It should be noted that, in some other embodiments of the present application, the system pop-up frame may be triggered by listening to the user clicking on a specific control. The specific controls may include the controls in the display interface of the reading APP, or the controls in the pull-down notification bar, or the controls in the floating ball, etc.
还需要说明的是,在本申请其他一些实施例中,当检测到用户点击系统弹框中的确认控件时,阅读APP可以不切换至分屏模式,可以继续保持全屏模式,翻译APP以悬浮窗模式启动。It should also be noted that, in some other embodiments of the present application, when it is detected that the user clicks on the confirmation control in the system pop-up box, the reading APP may not switch to the split-screen mode, but may continue to maintain the full-screen mode, and the translation APP can be displayed as a floating window. mode starts.
在本申请其他一些实施例中,若阅读APP与第一APP进行分屏显示,第一APP为除阅读APP和翻译APP外的其他APP,在阅读APP的界面上也可以触发系统弹框。当检测到用户点击系统弹框中的确认控件时,阅读APP可以继续保持分屏模式,翻译APP覆盖第一APP,以分屏模式启动。In some other embodiments of the present application, if the reading APP and the first APP are displayed in a split screen, the first APP is another APP except the reading APP and the translation APP, and the system pop-up frame can also be triggered on the reading APP interface. When it is detected that the user clicks the confirmation control in the system pop-up box, the reading APP can continue to maintain the split-screen mode, and the translation APP covers the first APP and starts in the split-screen mode.
本申请其他一些实施例中,翻译APP通过应用程序框架层获取另一侧应用,例如阅读APP,的窗口截图,从而从截图中提取文字信息,再将文字信息翻译成目标语言后,在翻译APP的界面显示出来。In some other embodiments of the present application, the translation APP obtains a screenshot of the window of another application, such as a reading APP, through the application framework layer, so as to extract text information from the screenshot, and then translate the text information into the target language, and then translate the APP. interface is displayed.
在本申请一些实施例中,翻译APP在系统注册全屏滑动事件监听,应用程序框架层的输入事件管理器可以向翻译APP提供全屏滑动事件监听。也就是说,翻译APP可以检测到整个显示屏的滑动事件。因而,翻译APP可以通过应用程序框架层监听到另一侧应用的滑动事件,例如阅读APP的滑动翻页事件,从而实现动态刷新翻译内容。In some embodiments of the present application, the translation APP registers the full-screen sliding event monitoring in the system, and the input event manager of the application framework layer can provide the full-screen sliding event monitoring for the translation APP. That is to say, the translation app can detect the sliding event of the entire display. Therefore, the translation APP can monitor the sliding event of the application on the other side through the application framework layer, such as the sliding page-turning event of the reading APP, so as to realize the dynamic refresh of the translation content.
为了更好地理解本申请一些实施例提供的翻译APP动态刷新翻译内容的实现原理,接着介绍翻译APP的内部软件模块的一示例性框图。应理解,此处仅为示例性描述,在其他实施例中,翻译APP可以包括更多或更少的软件模块。In order to better understand the implementation principle of the translation APP dynamically refreshing the translation content provided by some embodiments of the present application, an exemplary block diagram of the internal software module of the translation APP is introduced next. It should be understood that this description is merely exemplary, and in other embodiments, the translation APP may include more or less software modules.
参见图2B所示示例,翻译APP的内部软件模块包括:用户界面(user interface,UI)显示,滑动事件监听,截图处理,文本提取,翻译引擎,和语音选择等模块。Referring to the example shown in FIG. 2B , the internal software modules of the translation APP include: user interface (UI) display, sliding event monitoring, screenshot processing, text extraction, translation engine, and voice selection modules.
UI显示模块,用于显示用户界面等。例如翻译APP的各个界面,包括主界面、子界面、翻译结果显示界面等。UI display module, used to display user interface, etc. For example, translate the various interfaces of the APP, including the main interface, sub-interface, and translation result display interface.
语言选择模块,用于供用于选择源语言,和/或,目标语言。Language selection module for selecting source language, and/or target language.
滑动事件监听模块,用于在分屏状态下监听全屏滑动事件,例如阅读APP中的滑动翻页事件。The sliding event monitoring module is used to monitor the full-screen sliding event in the split-screen state, such as the sliding page-turning event in the reading APP.
截图处理模块,用于在分屏状态下,响应于滑动事件监听模块监听到滑动事件,截取另一侧APP显示内容的截图。The screenshot processing module is used to take a screenshot of the displayed content of the APP on the other side in response to the sliding event monitoring module listening to the sliding event in the split-screen state.
文本提取模块,用于从另一侧APP显示内容的截图中提取文本信息。The text extraction module is used to extract text information from the screenshot of the displayed content of the APP on the other side.
翻译引擎模块,用于将提取的文本信息,翻译成目标语言,获得最终要显示的信息。The translation engine module is used to translate the extracted text information into the target language to obtain the final information to be displayed.
在本申请一些实施例中,翻译结果显示方法是系统级的技术方案,翻译APP是系统级应用。本申请实施例的技术方案,不依赖于具体的应用实现,支持分屏显示的第三方应用都可以支持。In some embodiments of the present application, the translation result display method is a system-level technical solution, and the translation APP is a system-level application. The technical solutions of the embodiments of the present application do not depend on specific application implementation, and can be supported by any third-party application that supports split-screen display.
以下实施例可以在具有上述硬件结构和软件结构的电子设备100上实现。以下实施例将以平板电脑为例,对本申请实施例提供的翻译结果显示方法进行说明。应理解,平板电脑仅为示例性描述,不能解释为对本申请的限制。The following embodiments can be implemented on the electronic device 100 having the above-mentioned hardware structure and software structure. The following embodiments will take a tablet computer as an example to describe the translation result display method provided by the embodiments of the present application. It should be understood that the tablet computer is merely an exemplary description and should not be construed as a limitation of the present application.
参见图3A所示,为本申请一实施例提供的一种翻译结果显示方法的流程示意图。Referring to FIG. 3A , it is a schematic flowchart of a method for displaying translation results according to an embodiment of the present application.
S310,接收到用户开启阅读APP的操作,打开阅读APP。S310, an operation of opening the reading APP by the user is received, and the reading APP is opened.
在本申请实施例中,以阅读APP作为示例性说明。应理解,在本申请其他示例中,阅读APP可以替换成其他APP,例如图库、办公软件、短信息、浏览器、新闻、或即时通讯等APP,本申请对此不予限制。电子设备安装的APP可以是操作系统提供的原生APP,也可以是用户自行安装的第三方APP。In the embodiments of the present application, the reading APP is used as an exemplary description. It should be understood that in other examples of this application, the reading APP can be replaced with other APPs, such as gallery, office software, short message, browser, news, or instant messaging APP, which is not limited in this application. The APP installed on the electronic device may be a native APP provided by the operating system, or may be a third-party APP installed by the user.
在本申请一实现方式中,电子设备接收到用户点击平板电脑上安装的阅读APP图标的操作,响应于该操作,打开阅读APP,显示阅读界面。阅读界面可以为历史阅读界面,也可以为阅读APP的主界面等。In an implementation manner of the present application, the electronic device receives an operation of the user clicking on the icon of the reading APP installed on the tablet computer, and in response to the operation, opens the reading APP and displays the reading interface. The reading interface may be a historical reading interface, or a main interface of a reading APP, or the like.
S320,响应于监听到的手势事件,触发系统弹框,所述系统弹框为询问用户是否进入分屏翻译界面的系统弹框。S320 , triggering a system pop-up frame in response to the monitored gesture event, where the system pop-up frame is a system pop-up frame that asks the user whether to enter the split-screen translation interface.
在本申请实施例中,手势事件可以包括平板电脑监听到用户在阅读APP的任一显示界面执行预设触摸操作。预设触摸操作包括但不限于三指捏合操作、或点击特定控件等操作。该特定控件为预设控件,可以包括阅读APP显示界面的菜单栏中的预设控件,下拉通知栏中的预设控件,或悬浮球中的预设控件等。In this embodiment of the present application, the gesture event may include that the tablet computer monitors that the user performs a preset touch operation on any display interface of the reading APP. Preset touch operations include, but are not limited to, a three-finger pinch operation, or operations such as clicking on a specific control. The specific controls are preset controls, which may include preset controls in the menu bar of the display interface of the reading APP, preset controls in the pull-down notification bar, or preset controls in the floating ball, and the like.
需要说明的是,更一般地,在与其他预设触摸操作不相冲突的情形下,触发系统弹框的预设触摸操作可以包括但不限于:单指或多指长按操作、多指捏合(或称收缩)操作、多指放大(或称展开)操作、指关节敲击操作、单指或多指按预设轨迹滑动操作等。It should be noted that, more generally, in a situation that does not conflict with other preset touch operations, the preset touch operations that trigger the system pop-up frame may include but are not limited to: single-finger or multiple-finger long-press operations, multiple-finger pinch operations (or shrinking) operation, multi-finger zooming (or expanding) operation, knuckle tapping operation, single-finger or multi-finger sliding operation according to a preset trajectory, etc.
其中,单指或多指长按操作包括单指或多指按压触摸屏的时长超过第一时长的操作,其中第一时长为时长阈值。多指捏合或放大操作包括二指、三指、四指或五指等捏合或放大的操作。指关节敲击操作包括单指或多指关节单击、双击或三击触摸屏的操作。单指或多指按预设轨迹滑动包括单指或多指在触摸屏上向上、向下、向左或向右滑动等的操作。Wherein, the single-finger or multi-finger long-press operation includes an operation in which the duration of single-finger or multiple-finger pressing on the touch screen exceeds a first duration, where the first duration is a duration threshold. Multi-finger pinch-in or zoom-in operations include two-finger, three-finger, four-finger, or five-finger pinch-in or zoom-in operations. Knuckle-tapping operations include single- or multi-knuckle click, double-tap, or triple-tap on the touch screen. Single-finger or multi-finger sliding according to a preset track includes operations such as single-finger or multi-finger sliding up, down, left or right on the touch screen.
作为本申请一非限制性示例,如图3B所示,平板电脑检测到用户在阅读APP的显示界面执行三指捏合的触摸操作。响应于该触摸操作,触发系统弹框。在图3B中,平板电脑加载的系统弹框中显示“是否进入分屏翻译界面”字样。系统弹框中还包括选择控件,“是”和“取消”。As a non-limiting example of the present application, as shown in FIG. 3B , the tablet computer detects that the user performs a three-finger pinch touch operation on the display interface of the reading APP. In response to the touch operation, the system popup is triggered. In Fig. 3B, the words "whether to enter the split-screen translation interface" are displayed in the system pop-up box loaded on the tablet computer. The system popup also includes selection controls, "Yes" and "Cancel".
S330,接收到用户输入的确认操作,平板电脑响应于确认操作,进入分屏显示状态,一侧显示阅读APP,另一侧显示翻译APP。S330 , a confirmation operation input by the user is received, and the tablet computer enters a split-screen display state in response to the confirmation operation, with a reading APP displayed on one side and a translation APP displayed on the other side.
在本申请实施例中,确认操作是指同意进入翻译分屏翻译界面的用户操作。例如,可以如点击 图3B所示的系统弹框中的“是”控件的触摸操作,或控制光标移动到“是”控件所在位置后点击鼠标的光标控制操作等。又如,可以如用户语音输入“确认进入分屏翻译界面”或“确认”等的预设语音控制操作。在接收到用户输入的确认操作后进入分屏显示状态,可以防止误操作引发分屏翻译功能。In this embodiment of the present application, the confirmation operation refers to a user operation of agreeing to enter the translation split-screen translation interface. For example, the touch operation of clicking the "Yes" control in the system pop-up box shown in FIG. 3B, or the cursor control operation of clicking the mouse after moving the cursor to the position of the "Yes" control, etc. For another example, a preset voice control operation such as "confirm to enter the split-screen translation interface" or "confirm" may be input by the user's voice. Enter the split-screen display state after receiving the confirmation operation input by the user, which can prevent the split-screen translation function caused by misoperation.
需要说明的是,若接收到用户输入的取消操作,系统弹框消失,用户继续阅读。取消操作是指不同意进入翻译分屏翻译界面的用户操作。例如,可以如点击图3B所示的系统弹框中的“取消”控件的触摸操作。It should be noted that if a cancel operation input by the user is received, the system pop-up box disappears, and the user continues reading. Cancel operation refers to the user operation that does not agree to enter the translation split-screen translation interface. For example, the touch operation of the "Cancel" control in the system pop-up box shown in FIG. 3B can be clicked.
还需要说明的是,若在一个时长阈值内未接收到用户的确认操作,系统弹框消失,用户继续阅读。It should also be noted that if the user's confirmation operation is not received within a duration threshold, the system pop-up box disappears, and the user continues reading.
在本申请一实现方式中,若平板电脑当前为横屏,则分屏显示状态为将阅读APP的显示区域设置在左半边,将翻译APP的显示区域设置在右半边,如图3C所示;或者,将阅读APP的显示区域设置在右半边,将翻译APP的显示区域设置在左半边。若平板电脑当前为竖屏,则分屏显示状态为将阅读APP的显示区域设置在上半边,将翻译APP的显示区域设置在下半边,如图3D所示;或者,将阅读APP的显示区域设置在下半边,将翻译APP的显示区域设置在上半边。也就是说,若平板电脑当前为横屏,则分屏采用横屏显示布局,左右分屏显示。若平板电脑当前为竖屏,则分屏采用竖屏显示布局,上下分屏显示。In an implementation of the present application, if the tablet computer is currently in a landscape orientation, the split-screen display state is to set the display area of the reading APP on the left half, and set the display area of the translation APP on the right half, as shown in FIG. 3C ; Or, set the display area of the reading APP to the right half, and set the display area of the translation APP to the left half. If the tablet computer is currently in vertical screen, the split-screen display state is to set the display area of the reading APP in the upper half, and set the display area of the translation APP in the lower half, as shown in Figure 3D; or, set the display area of the reading APP to the upper half. In the lower half, set the display area of the translation app to the upper half. That is to say, if the tablet computer is currently in a landscape orientation, the split screen adopts a landscape display layout, and the left and right split screens are displayed. If the tablet computer is currently in a vertical screen, the split screen adopts a vertical screen display layout, and the upper and lower screens are displayed in a split screen.
需要说明的是,分屏的竖屏显示布局或横屏显示布局,可以占满整个显示屏,也可以不占满整个显示屏。当竖屏显示布局或横屏显示布局占满整个显示屏时,可以同时显示更多内容,方便用户查看。It should be noted that the vertical screen display layout or the horizontal screen display layout of the split screen may or may not occupy the entire display screen. When the vertical screen display layout or the horizontal screen display layout occupies the entire display screen, more content can be displayed at the same time, which is convenient for users to view.
还需要说明的是,翻译APP的显示区域和阅读APP的显示区域可以具备相同大小,也可以具备不同大小。阅读APP和翻译APP的显示区域的大小,可以由系统默认设置,也可以由系统根据显示区域内容的多少进行适应性调整,也可以由用户根据显示屏的大小和个性化需求设置。在本申请一实现方式中,翻译APP和阅读APP的显示界面大小可以由系统根据显示内容的多少进行调整,便于用户查看。It should also be noted that the display area of the translation APP and the display area of the reading APP may have the same size, or may have different sizes. The size of the display area of the reading APP and the translation APP can be set by the system by default, or it can be adaptively adjusted by the system according to the content of the display area, or it can be set by the user according to the size of the display screen and individual needs. In an implementation manner of the present application, the size of the display interface of the translation APP and the reading APP can be adjusted by the system according to the amount of displayed content, which is convenient for the user to view.
S340,接收用户在翻译APP上选择的源语言和目标语言。S340: Receive the source language and the target language selected by the user on the translation APP.
源语言是阅读APP上文字所属语言。目标语言是翻译结果所属语言。目标语言通常为用户母语;或者,用户没有阅读障碍的语言。The source language is the language of the text on the reading app. The target language is the language in which the translation results belong. The target language is usually the user's native language; alternatively, a language in which the user is not dyslexic.
在本申请一实现方式中,翻译APP的显示界面上设置有语言切换控件,可以供用户切换源语言和目标语言。例如,参见图3C、图3D和图3E所示,翻译APP的显示界面上设置源语言切换控件31和目标语言切换控件32。用户点击源语言切换控件31,可以在下拉菜单中选择源语言,如图3E中的(A)图所示。用户点击目标语言切换控件32,可以在下拉菜单中选择目标语言,如图3E中的(B)图所示。In an implementation manner of the present application, a language switching control is provided on the display interface of the translation APP, which can be used by the user to switch the source language and the target language. For example, as shown in FIG. 3C , FIG. 3D and FIG. 3E , a source language switching control 31 and a target language switching control 32 are set on the display interface of the translation APP. The user clicks the source language switch control 31, and can select the source language in the pull-down menu, as shown in (A) of FIG. 3E. The user clicks the target language switching control 32, and can select the target language in the pull-down menu, as shown in (B) of FIG. 3E.
在本申请另一实现方式中,翻译APP的显示界面上设置有语言输入控件,可以供用户输入源语言和目标语言。例如,在翻译APP的显示界面上设置两个输入框,一个输入框用于输入源语言,另一个输入框用于输入目标语言。In another implementation manner of the present application, a language input control is provided on the display interface of the translation APP, which can allow the user to input the source language and the target language. For example, two input boxes are set on the display interface of the translation APP, one input box is used for inputting the source language, and the other input box is used for inputting the target language.
在本申请其他一些实施例中,翻译APP可以自动识别阅读APP中待翻译的文本信息的语言,并以此作为源语言。在这些实施例中,不再需要用户选择源语言,简化了用户操作。In some other embodiments of the present application, the translation APP can automatically identify the language of the text information to be translated in the reading APP, and use this language as the source language. In these embodiments, the user is no longer required to select the source language, simplifying user operations.
在本申请其他一些实施例中,翻译APP可以记录用户历史使用习惯,根据用户历史使用习惯确定目标语言。在这些实施例中,不再需要用户选择目标语言,简化了用户操作。In some other embodiments of the present application, the translation APP may record the user's historical usage habits, and determine the target language according to the user's historical usage habits. In these embodiments, the user is no longer required to select the target language, simplifying the user operation.
在后续的示例中,为了描述的方便,以源语言为英文,目标语言为中文进行示例性说明。应理解,此示例不能解释为对本申请的限制。In the following examples, for the convenience of description, the source language is English and the target language is Chinese for illustrative description. It should be understood that this example should not be construed as a limitation of the present application.
S350,阅读APP显示界面的文本信息,在翻译APP上以翻译后的目标语言进行显示。S350 , read the text information on the display interface of the APP, and display it in the translated target language on the translation APP.
在确定了源语言和目标语言之后,翻译APP将阅读APP显示界面的文本信息翻译成目标语言,并显示翻译结果。After determining the source language and the target language, the translation APP translates the text information on the display interface of the reading APP into the target language, and displays the translation result.
在本申请一实现方式中,翻译APP翻译阅读APP中文本格式的文本信息。例如,如图3F所示,翻译APP将阅读APP的文本格式的英文“Walk into Switzerland Switzerland is rich in tourism resources and has a reputation as a world park.”,翻译成中文:“走进瑞士瑞士旅游资源丰富,素有世界公园的美誉。”In an implementation manner of the present application, the translation APP translates the text information in the text format in the reading APP. For example, as shown in Figure 3F, the translation APP will read the English "Walk into Switzerland Switzerland Switzerland is rich in tourism resources and has a reputation as a world park." in the text format of the APP, and translate it into Chinese: "Walk into Switzerland Switzerland tourism resources It is rich and has the reputation of a world park.”
在本申请另一实现方式中,翻译APP翻译阅读APP中文本格式、图片或布局内容等中的一种或多种格式的文本信息。例如,如图3G所示,翻译APP将阅读APP中文本格式和图片中的英文文本进行了翻译,并显示翻译结果。In another implementation manner of the present application, the translation APP translates text information in one or more formats of text formats, pictures, or layout content in the reading APP. For example, as shown in Figure 3G, the translation APP translates the English text in the text format in the reading APP and the picture, and displays the translation result.
应理解的是,更一般地,对阅读APP中显示内容的格式无限制。显示内容可以是文本格式、图片、布局控件或者其他任何用户可见的文件显示形式。这些格式的显示内容都可以经过翻译后在翻译APP上显示出来。It should be understood that, more generally, there is no restriction on the format of the content displayed in the reading APP. The displayed content can be in text format, pictures, layout controls, or any other user-visible file display. The displayed content in these formats can be translated and displayed on the translation app.
下面以平板电脑为横屏显示为例,对翻译APP对文本信息进行翻译并显示翻译结果,即步骤S350的实现流程进行示例性说明。应理解,竖屏显示下的流程与此示例类似,不再赘述。如图4A所示,步骤S350包括步骤S410至S440。Taking the tablet computer as an example of horizontal screen display, the translation APP translates the text information and displays the translation result, that is, the implementation process of step S350 is exemplarily described. It should be understood that the process in the vertical screen display is similar to this example, and will not be repeated here. As shown in FIG. 4A, step S350 includes steps S410 to S440.
S410,获取阅读APP的显示截图。S410, acquiring a display screenshot of the reading APP.
在翻译APP以分屏模式启动,接收到用户输入的源语言和目标语言后,开始执行步骤S410,获取阅读APP的显示截图。After the translation APP is started in the split-screen mode and the source language and the target language input by the user are received, step S410 is started to obtain a display screenshot of the reading APP.
在本申请一实现方式中,翻译APP调用系统接口截取平板电脑整个屏幕的截图,截图的大小是整个屏幕的大小。例如,图4B中的(A)图所示,为整个屏幕的截图的示例。然后,翻译APP获取自身窗口区域大小,获取平板电脑的宽和高。然后,翻译APP可以根据平板电脑的宽和高,以及自身窗口区域大小,得到阅读APP的窗口区域大小。最后,在整个屏幕的截图中,根据阅读APP的窗口区域大小,得到阅读APP窗口区域的图片。例如,图4B中的(B)图所示,为阅读APP窗口区域的截图的示例。In an implementation manner of the present application, the translation APP calls the system interface to take a screenshot of the entire screen of the tablet computer, and the size of the screenshot is the size of the entire screen. For example, (A) in FIG. 4B is an example of a screenshot of the entire screen. Then, the translation APP obtains the size of its own window area, and obtains the width and height of the tablet. Then, the translation APP can obtain the window area size of the reading APP according to the width and height of the tablet computer and the size of its own window area. Finally, in the screenshot of the entire screen, according to the size of the window area of the reading APP, a picture of the window area of the reading APP is obtained. For example, as shown in (B) of FIG. 4B , it is an example of a screenshot of the window area of the reading APP.
S420,从显示截图中提取文本。S420, extract text from the displayed screenshot.
在本申请一实现方式中,通过光学字符识别(Optical Character Recognition,OCR)技术,提取显示截图中的文本。In an implementation manner of the present application, the text in the displayed screenshot is extracted through an Optical Character Recognition (Optical Character Recognition, OCR) technology.
S430,将提取出的文本提交给翻译引擎进行翻译,得到翻译结果。S430, submit the extracted text to a translation engine for translation, and obtain a translation result.
在本申请一实现方式中,翻译引擎将提取出的文本,翻译成最终要显示的目标语言的文本,即翻译结果。In an implementation manner of the present application, the translation engine translates the extracted text into text in the target language to be finally displayed, that is, a translation result.
S440,在翻译APP的显示界面显示翻译结果。S440, displaying the translation result on the display interface of the translation APP.
至此,翻译APP完成对阅读APP中待翻译文本信息的翻译。So far, the translation APP has completed the translation of the text information to be translated in the reading APP.
本申请实施例,一方面,通过用户简单操作,就可以快速进入分屏显示状态,让用户可以快速获取翻译结果,提高了翻译和阅读的效率。另一方面,显示屏同时显示翻译APP和阅读APP,增加了显示屏显示的信息量,提高了多任务交互的效率。In the embodiment of the present application, on the one hand, the user can quickly enter the split-screen display state through a simple operation, so that the user can quickly obtain the translation result, thereby improving the efficiency of translation and reading. On the other hand, the display screen displays the translation APP and the reading APP at the same time, which increases the amount of information displayed on the display screen and improves the efficiency of multi-task interaction.
可选地,在本申请其他一些实施例中,触发系统弹框的用户操作可以不限于手势触摸操作,还 可以包括输入预设语音的语音控制操作、预设的光标控制操作等。Optionally, in some other embodiments of the present application, the user operation that triggers the system pop-up frame may not be limited to the gesture touch operation, but may also include a voice control operation of inputting a preset voice, a preset cursor control operation, and the like.
作为本申请一非限制性示例,平板电脑通过语音助手,检测到用户语音输入预设语音,例如“分屏翻译”或“进入分屏翻译”等,触发系统弹框。作为本申请一非限制性示例,用户通过平板电脑的物理键盘或鼠标等控制光标移动,控制光标悬停到阅读APP的显示界面上预设按钮所在位置,若用户点击鼠标,或悬停在预设按钮所在位置超过第二时长,触发系统弹框。其中第二时长为时长阈值。在触发系统弹框后,平板电脑响应于用户输入的确认操作,进入分屏显示状态,一侧显示阅读APP,另一侧显示翻译APP。As a non-limiting example of the present application, the tablet computer detects the user's voice input preset voice, such as "split-screen translation" or "enter split-screen translation" through the voice assistant, and triggers the system pop-up box. As a non-limiting example of the present application, the user controls the cursor movement through the physical keyboard or mouse of the tablet computer, and controls the cursor to hover to the position of the preset button on the display interface of the reading APP. If the user clicks the mouse, or hovers over the preset button If the position of the button exceeds the second time period, the system popup will be triggered. The second duration is a duration threshold. After triggering the system pop-up box, the tablet computer enters the split-screen display state in response to the confirmation operation input by the user, with the reading APP displayed on one side and the translation APP displayed on the other side.
需要说明的是,在本申请其他一些实施例中,平板电脑检测到用户输入预设语音的语音控制操作,或预设手势触摸操作,或预设光标控制操作后,可以不用触发系统弹框,翻译APP也就不需要再接收用户输入的确认操作。在这些实施例中,平板电脑响应于用户输入预设语音的语音控制操作、预设手势触摸操作、或预设光标控制操作,进入分屏显示状态,一侧显示阅读APP,另一侧显示翻译APP。通过这种方式,进一步简化了用户操作,减小了用户交互成本,提高了操作效率。It should be noted that, in some other embodiments of the present application, after the tablet computer detects the voice control operation of the user inputting the preset voice, or the preset gesture touch operation, or the preset cursor control operation, it is not necessary to trigger the system pop-up box, The translation APP also does not need to receive the confirmation operation input by the user. In these embodiments, the tablet computer enters a split-screen display state in response to a voice control operation, a preset gesture touch operation, or a preset cursor control operation inputting a preset voice by the user, with the reading APP displayed on one side and the translation displayed on the other side. APP. In this way, the user operation is further simplified, the user interaction cost is reduced, and the operation efficiency is improved.
可选地,在本申请其他一些实施例中,若阅读APP的显示界面与第一APP的显示界面为分屏显示状态,第一APP为除翻译APP和阅读APP外的其他APP,例如即时通讯APP等。此种情形下,用户也可以在阅读APP的显示界面触发系统弹框。若用户触发了系统弹框,平板电脑接收到用户输入的确认进行分屏翻译界面的操作,则翻译APP以覆盖第一APP的方式,在分屏模式下启动,如图5A所示。在一些实现方式中,若接收到关闭翻译APP的用户操作,则第一APP被激活,以覆盖翻译APP的方式,在分屏模式下启动。Optionally, in some other embodiments of the present application, if the display interface of the reading APP and the display interface of the first APP are in a split-screen display state, the first APP is an APP other than the translation APP and the reading APP, such as instant messaging. APP, etc. In this case, the user can also trigger the system popup on the display interface of the reading APP. If the user triggers the system popup, and the tablet computer receives the confirmation input from the user to perform the operation of the split-screen translation interface, the translation APP starts in the split-screen mode by covering the first APP, as shown in FIG. 5A . In some implementations, if a user operation for closing the translation APP is received, the first APP is activated, and starts in a split-screen mode in a manner of covering the translation APP.
可选地,在本申请其他一些实施例中,当阅读APP的显示界面与翻译APP的显示界面为分屏显示状态,用户返回桌面,例如点击home键等回到桌面,或者从最近任务切换到其他的应用,再次切回到阅读APP时,仍然将阅读APP与翻译APP在分屏模式下进行显示。在这些实施例中,当接收到用户输入的返回桌面或切换到其他任务等的操作,系统记录阅读APP和翻译APP的分屏显示状态,将阅读APP和翻译APP切换至停止(stop)状态,当接收到用户激活阅读APP的操作,系统根据阅读APP和翻译APP的分屏显示状态,激活阅读APP和翻译APP,并在分屏模式下进行显示。也就是说,在这些实施例中,阅读APP和翻译APP形成分屏后,两个应用的显示界面即窗口绑定在一起,无论是回到桌面或者进入其他应用等再激活阅读APP,阅读APP和翻译APP仍以分屏状态显示。Optionally, in some other embodiments of the present application, when the display interface of the reading APP and the display interface of the translation APP are in a split-screen display state, the user returns to the desktop, for example, clicks the home button to return to the desktop, or switches from recent tasks to For other applications, when switching back to the reading APP again, the reading APP and the translation APP will still be displayed in split-screen mode. In these embodiments, when an operation of returning to the desktop or switching to other tasks inputted by the user is received, the system records the split-screen display state of the reading APP and the translation APP, and switches the reading APP and the translation APP to the stop state, When receiving the user's operation of activating the reading APP, the system activates the reading APP and the translation APP according to the split-screen display status of the reading APP and the translation APP, and displays them in the split-screen mode. That is to say, in these embodiments, after the reading APP and the translation APP form a split screen, the display interfaces of the two applications, that is, the windows, are bound together. Whether it is to return to the desktop or enter other applications, and then activate the reading APP, the reading APP And the translation app is still displayed in a split-screen state.
可选地,在本申请其他一些实施例中,平板电脑检测到用户输入预设语音的语音控制操作、预设手势触摸操作、或预设光标控制操作后,或,平板电脑接收到用户输入的确认操作后,平板电脑响应于该语音控制操作,或预设手势触摸操作,或预设光标控制操作,或确认操作,阅读APP可以保持原来的显示界面大小,例如全屏显示,也可以避免翻译APP的遮挡缩放到预设大小,翻译APP以悬浮窗模式叠加显示在阅读APP上,例如图5B所示。在这些实施例中,悬浮窗可以为透明或不透明的悬浮窗。阅读APP和翻译APP的显示区域的大小,可以由系统默认设置,也可以由用户根据显示屏的大小和个性化需求设置。Optionally, in some other embodiments of the present application, after the tablet computer detects a voice control operation, a preset gesture touch operation, or a preset cursor control operation that the user inputs a preset voice, or, the tablet computer receives an input from the user. After confirming the operation, the tablet computer responds to the voice control operation, or the preset gesture touch operation, or the preset cursor control operation, or the confirmation operation, and the reading APP can keep the original display interface size, such as full-screen display, and can also avoid the translation of the APP. The occlusion is scaled to the preset size, and the translation APP is superimposed and displayed on the reading APP in a floating window mode, for example, as shown in Figure 5B. In these embodiments, the floating window may be a transparent or opaque floating window. The size of the display area of the reading APP and the translation APP can be set by the system by default, or can be set by the user according to the size of the display screen and individual needs.
可选地,在本申请其他一些实施例中,继续参见图5B所示,翻译APP的悬浮窗上可以设置全屏和缩放显示控件51,和/或,退出悬浮窗控件52。用户点击该全屏和缩放显示控件51可以在全屏显示与悬浮窗显示间进行切换。用户点击该退出悬浮窗控件52可以退出悬浮窗,即关闭翻译APP。在本申请一些实施例中,拖曳翻译APP悬浮窗的边线可以放大或缩小悬浮窗。Optionally, in some other embodiments of the present application, continuing to refer to FIG. 5B , a full-screen and zoom display control 51 may be set on the suspension window of the translation APP, and/or the exit suspension window control 52 may be set. The user can switch between the full screen display and the floating window display by clicking the full screen and zoom display control 51 . The user can click the exit suspension window control 52 to exit the suspension window, that is, close the translation APP. In some embodiments of the present application, dragging the border of the translation APP floating window can enlarge or reduce the floating window.
可选地,在本申请其他一些实施例中,翻译APP以悬浮窗模式叠加显示在阅读APP上,翻译APP的悬浮窗上可以设置移动控件。作为一非限制性示例,继续参见图5B所示,移动控件可以为顶 部横条53,用户可以拖动悬浮窗顶部横条53,移动悬浮窗的位置。Optionally, in some other embodiments of the present application, the translation APP is superimposed and displayed on the reading APP in a floating window mode, and a mobile control may be set on the floating window of the translation APP. As a non-limiting example, continuing to refer to Fig. 5B, the moving control can be the top horizontal bar 53, and the user can drag the top horizontal bar 53 of the floating window to move the position of the floating window.
可选地,在本申请其他一些实施例中,可以通过接收到的用户作用于移动控件的操作,将悬浮窗切换为分屏。Optionally, in some other embodiments of the present application, the floating window may be switched to a split screen through the received operation of the user acting on the mobile control.
作为一非限制性示例,平板电脑当前为横屏时,长按悬浮窗顶部横条53向左或向右拖动切换至分屏状态。如图5C所示,长按悬浮窗顶部横条53向左拖动切换至分屏状态时,翻译APP的分屏窗口在左半边,阅读APP的分屏窗口在右半边;长按悬浮窗顶部横条53向右拖动切换至分屏状态时,翻译APP的分屏窗口在右半边,阅读APP的分屏窗口在左半边。As a non-limiting example, when the tablet computer is currently in landscape orientation, long press the horizontal bar 53 at the top of the floating window and drag it to the left or right to switch to the split-screen state. As shown in FIG. 5C , when the horizontal bar 53 at the top of the floating window is long-pressed and dragged to the left to switch to the split-screen state, the split-screen window of the translation APP is on the left half, and the split-screen window of the reading APP is on the right half; long-press the top of the floating window When the horizontal bar 53 is dragged to the right to switch to the split-screen state, the split-screen window of the translation APP is on the right half, and the split-screen window of the reading APP is on the left half.
作为另一非限制性示例,平板电脑当前为竖屏时,长按悬浮窗顶部横条53向上或向下拖动切换至分屏状态。如图5D所示,长按悬浮窗顶部横条53向上拖动切换至分屏状态时,翻译APP的分屏窗口在上半边,阅读APP的分屏窗口在下半边;长按悬浮窗顶部横条53向下拖动切换至分屏状态时,翻译APP的分屏窗口在下半边,阅读APP的分屏窗口在上半边。As another non-limiting example, when the tablet computer is currently in a vertical screen, long press the horizontal bar 53 at the top of the floating window and drag it upwards or downwards to switch to the split screen state. As shown in FIG. 5D , when long-pressing and dragging the horizontal bar 53 on the top of the floating window to switch to the split-screen state, the split-screen window of the translation APP is on the upper half, and the split-screen window of the reading APP is on the lower half; long-press the horizontal bar on the top of the floating window 53 When dragging down to switch to the split-screen state, the split-screen window of the translation app is on the bottom half, and the split-screen window of the reading app is on the top half.
也就是说,若平板电脑当前为横屏,则采用横屏显示布局,左右分屏显示。若平板电脑当前为竖屏,则采用竖屏显示布局,上下分屏显示。That is to say, if the tablet computer is currently in a landscape orientation, the landscape display layout is adopted, and the left and right split-screen displays are used. If the tablet computer is currently in a vertical screen, the vertical screen display layout is adopted, and the upper and lower screens are displayed.
可选地,在本申请其他一些实施例中,当阅读APP与翻译APP进行分屏显示后,可以通过接收到的用户操作,将分屏切换为悬浮窗。如图5E和图5F所示,阅读APP和/或翻译APP的分屏窗口可以设置全屏和缩放显示控件51,和/或,退出分屏控件52,和/或,移动控件。移动控件可以为顶部横条53。Optionally, in some other embodiments of the present application, after the reading APP and the translation APP are displayed in a split screen, the split screen may be switched to a floating window through a received user operation. As shown in FIG. 5E and FIG. 5F , the split screen window of the reading APP and/or the translation APP can be set with full screen and zoom display controls 51 , and/or exit split screen controls 52 , and/or move controls. The movement control can be the top bar 53 .
作为一非限制性示例,平板电脑当前为横屏。如图5E所示,翻译APP的分屏窗口在左半边,阅读APP的分屏窗口在右半边。长按翻译APP分屏窗口的顶部横条53向右拖动切换至悬浮窗,阅读APP的分屏窗口大小可以扩大到整个显示屏。作为另一非限制性示例,如图5F所示,翻译APP的分屏窗口在左半边,阅读APP的分屏窗口在右半边。长按阅读APP分屏窗口的顶部横条53向左拖动切换至悬浮窗,翻译APP的分屏窗口大小可以扩大到整个显示屏。As a non-limiting example, the tablet is currently in landscape orientation. As shown in FIG. 5E , the split-screen window of the translation APP is on the left half, and the split-screen window of the reading APP is on the right half. Long press the top horizontal bar 53 of the translation APP split screen window and drag it to the right to switch to the floating window. The size of the split screen window of the reading APP can be expanded to the entire display screen. As another non-limiting example, as shown in FIG. 5F , the split-screen window of the translation APP is on the left half, and the split-screen window of the reading APP is on the right half. Long press the top horizontal bar 53 of the split screen window of the reading APP and drag it to the left to switch to the floating window. The size of the split screen window of the translation APP can be expanded to the entire display screen.
作为另一非限制性示例,平板电脑当前为竖屏。如图5G所示,翻译APP的分屏窗口在上半边,阅读APP的分屏窗口在下半边。长按翻译APP分屏窗口的顶部横条53向下拖动切换至悬浮窗,阅读APP的分屏窗口大小可以扩大到整个显示屏。作为另一非限制性示例,如图5H所示,翻译APP的分屏窗口在上半边,阅读APP的分屏窗口在下半边。长按阅读APP分屏窗口的顶部横条53向上拖动切换至悬浮窗,翻译APP的分屏窗口大小可以扩大到整个显示屏。As another non-limiting example, tablet computers are currently in portrait orientation. As shown in Figure 5G, the split-screen window of the translation app is on the upper half, and the split-screen window of the reading app is on the bottom half. Long press the top bar 53 of the translation APP split-screen window and drag it downward to switch to the floating window. The size of the split-screen window of the reading APP can be expanded to the entire display screen. As another non-limiting example, as shown in FIG. 5H , the split-screen window of the translation APP is on the upper half, and the split-screen window of the reading APP is on the lower half. Long press the top horizontal bar 53 of the split screen window of the reading APP and drag it upward to switch to the floating window. The size of the split screen window of the translation APP can be expanded to the entire display screen.
在前述任一翻译结果显示方法实施例的基础上,本申请另外三个实施例提供了另三种翻译结果显示方法。本申请另外三个实施例以在图3A所示实施例基础上进行改进为例,进行说明。On the basis of any of the foregoing translation result display method embodiments, the other three embodiments of the present application provide another three translation result display methods. The other three embodiments of the present application are described by taking improvements based on the embodiment shown in FIG. 3A as an example.
作为本申请一实施例,如图6A所示,在图3A所示实施例的基础上,本申请实施例在步骤S350之后还包括步骤S610至S620。As an embodiment of the present application, as shown in FIG. 6A , on the basis of the embodiment shown in FIG. 3A , the embodiment of the present application further includes steps S610 to S620 after step S350 .
S610,接收到用户在阅读APP中输入的滑动操作。S610, a sliding operation input by the user in the reading APP is received.
S620,响应于该滑动操作,阅读APP显示新文本,翻译APP针对阅读APP上显示的新文本进行翻译,并刷新显示。S620, in response to the sliding operation, the reading APP displays new text, and the translation APP translates the new text displayed on the reading APP, and refreshes the display.
本申请实施例中,阅读APP的滑动操作是指触发翻页事件的用户滑动操作,即触发显示内容更新的用户操作。翻译APP在系统注册全屏滑动事件监听,应用程序框架层的输入事件管理器可以向翻译APP提供全屏滑动事件监听。因此,翻译APP可以通过检测整个显示屏的滑动事件,从而判定阅读APP是否发生翻页事件。若接收到用户在阅读APP显示界面的滑动操作,可以认为阅读APP发生翻页事件,从而翻译APP针对新文本进行翻译,并刷新显示。In the embodiment of the present application, the sliding operation of the reading APP refers to a user sliding operation that triggers a page turning event, that is, a user operation that triggers an update of the displayed content. The translation APP registers full-screen sliding event monitoring in the system, and the input event manager of the application framework layer can provide full-screen sliding event monitoring to the translation APP. Therefore, the translation APP can determine whether a page turning event occurs in the reading APP by detecting the sliding event of the entire display screen. If the user's sliding operation on the display interface of the reading APP is received, it can be considered that a page turning event occurs in the reading APP, so that the translation APP translates the new text and refreshes the display.
滑动事件通常由按下(down)事件,若干个移动(move)事件,和松开(up)事件的事件序列组成。作为本申请一实现方式,翻译APP监听的滑动事件的处理逻辑包括:收到down事件和move事件,认为发生滑动事件,并记录滑动坐标序列直至收到up事件,根据up事件触发坐标位置判断,判断整个滑动坐标序列是否都在阅读APP的显示区域内,如果是,则认为发生了有效的滑动事件,翻译APP针对阅读APP上显示的新文本进行翻译,并刷新显示;如果否,则认为发生的滑动事件无效,翻译APP不响应。A sliding event usually consists of a down event, a sequence of several move events, and a release (up) event. As an implementation mode of the present application, the processing logic of the sliding event monitored by the translation APP includes: receiving a down event and a move event, deeming that a sliding event occurs, recording the sliding coordinate sequence until the up event is received, and judging the coordinate position according to the triggering of the up event, Determine whether the entire sliding coordinate sequence is in the display area of the reading APP. If so, it is considered that a valid sliding event has occurred. The translation APP translates the new text displayed on the reading APP and refreshes the display; if not, it is considered to have occurred. The swipe event is invalid, and the translation APP does not respond.
应理解的是,阅读APP监听滑动事件的处理逻辑相同,针对有效的滑动事件,阅读APP执行翻页功能,即更新显示内容;而针对无效的滑动事件,阅读APP不响应,即不更新显示内容。It should be understood that the processing logic of the reading APP monitoring sliding events is the same. For valid sliding events, the reading APP performs the page-turning function, that is, the display content is updated; and for invalid sliding events, the reading APP does not respond, that is, does not update the display content. .
在本申请实施例中,滑动操作包括翻上一页或翻下一页等的滑动操作,例如向左或向上滑动的翻上一页的操作,或,向下或向右滑动的翻下一页的操作等。当监听到滑动操作,阅读APP触发翻页事件,翻译APP获取阅读APP的显示截图,从显示截图中提取文本将提取出的文本提交给翻译引擎进行翻译,得到翻译结果,从而刷新显示。翻译APP刷新显示的流程与图3A所示实施例的步骤S350中显示翻译结果的流程相似,区别在于触发的条件不同,此处不再赘述。In this embodiment of the present application, the sliding operation includes a sliding operation of turning to the previous page or the next page, for example, the operation of turning left or upward to turn the previous page, or the downward or right sliding operation of turning to the next page Page operation, etc. When the sliding operation is monitored, the reading APP triggers a page-turning event, the translation APP obtains the display screenshot of the reading APP, extracts the text from the display screenshot, and submits the extracted text to the translation engine for translation, and the translation result is obtained, thereby refreshing the display. The process of refreshing and displaying the translation APP is similar to the process of displaying the translation result in step S350 of the embodiment shown in FIG. 3A , and the difference lies in the different triggering conditions, which will not be repeated here.
作为一非限制性示例,如图6B所示,平板电脑当前为横屏显示布局,为左右分屏显示。左半边为阅读APP的分屏窗口,右半边为翻译APP的分屏窗口。平板电脑接收到用户在阅读APP的分屏窗口输入的向上滑动操作。响应于该滑动操作,阅读APP显示下一页的内容,翻译APP根据阅读APP显示的新文本进行翻译,显示新的翻译结果。As a non-limiting example, as shown in FIG. 6B , the tablet computer is currently in a landscape display layout, which is a left-right split-screen display. The left half is the split screen window of the reading app, and the right half is the split screen window of the translation app. The tablet computer receives the upward swipe operation input by the user in the split-screen window of the reading APP. In response to the sliding operation, the reading APP displays the content of the next page, and the translation APP translates according to the new text displayed by the reading APP, and displays the new translation result.
在图6A所示实施例中,翻译界面可以自动同步显示新内容的翻译结果。因此,简化了用户操作,减小了用户交互成本,提高了效率。In the embodiment shown in FIG. 6A , the translation interface can automatically and synchronously display the translation result of the new content. Therefore, user operations are simplified, user interaction costs are reduced, and efficiency is improved.
作为本申请另一实施例,如图7A所示,在图3A所示实施例的基础上,本申请实施例在步骤S350之后还包括步骤S710至S720。As another embodiment of the present application, as shown in FIG. 7A , on the basis of the embodiment shown in FIG. 3A , the embodiment of the present application further includes steps S710 to S720 after step S350 .
S710,接收到用户输入的刷新翻译操作。S710, a refresh translation operation input by the user is received.
S720,响应于该刷新翻译操作,翻译APP针对阅读APP上当前显示的文本进行翻译,并刷新显示。S720, in response to the refresh translation operation, the translation APP translates the text currently displayed on the reading APP, and refreshes the display.
在实际生活中,虽然阅读APP在显示文档时通常会具备翻页功能,但是翻页事件可以不由滑动操作来触发。因此,区别于图6A所示实施例,在本申请实施例中,翻译APP增加了人工刷新翻译功能,可以人工实现文本内容与翻译结果同时显示,使得本申请实施例适用更多应用场景,更具普适性。In real life, although a reading APP usually has a page-turning function when displaying a document, the page-turning event may not be triggered by a sliding operation. Therefore, different from the embodiment shown in FIG. 6A , in the embodiment of the present application, the translation APP adds a manual refresh translation function, which can manually display the text content and the translation result at the same time, so that the embodiment of the present application is suitable for more application scenarios, and more Universal.
平板电脑接收到用户输入的刷新翻译操作,启用翻译APP的刷新翻译功能。刷新翻译操作可以包括触摸操作,语音控制操作,和/或,光标控制操作等。触摸操作包括点击预设控件或按照预设轨迹滑动等的触摸操作。语音控制操作包括输入预设语音的语音控制操作。光标控制操作包括控制光标悬停在预设控件所在位置等。The tablet computer receives the refresh translation operation input by the user, and enables the refresh translation function of the translation app. The refresh translation operation may include a touch operation, a voice control operation, and/or a cursor control operation, and the like. Touch operations include touch operations such as clicking on a preset control or sliding according to a preset track. The voice control operation includes a voice control operation of inputting a preset voice. Cursor control operations include controlling the cursor to hover over the position of the preset control, etc.
具体地,当监听到用户输入的刷新翻译操作,翻译APP获取阅读APP当前的显示截图,从当前的显示截图中提取文本将提取出的文本提交给翻译引擎进行翻译,得到翻译结果,从而刷新显示。翻译APP刷新显示的流程与图3A所示实施例的步骤S350中显示翻译结果的流程相似,区别在于触发的条件不同,此处不再赘述。Specifically, when monitoring the refresh translation operation input by the user, the translation APP obtains the current display screenshot of the reading APP, extracts the text from the current display screenshot, submits the extracted text to the translation engine for translation, and obtains the translation result, thereby refreshing the display . The process of refreshing and displaying the translation APP is similar to the process of displaying the translation result in step S350 of the embodiment shown in FIG. 3A , and the difference lies in the different triggering conditions, which will not be repeated here.
作为一非限制性示例,如图7B所示,翻译APP的显示界面设置了刷新控件71,通过接收到用户作用于刷新控件的点击操作,翻译APP获取阅读APP的显示截图,根据显示截图得到翻译结果,从而刷新显示。As a non-limiting example, as shown in FIG. 7B , a refresh control 71 is set on the display interface of the translation APP. After receiving the user's click operation on the refresh control, the translation APP obtains the display screenshot of the reading APP, and obtains the translation according to the display screenshot. As a result, the display is refreshed.
作为另一非限制性示例,平板电脑接收到用户语音输入的预设语音控制操作,例如用户语音输入“刷新翻译”或“刷新翻译结果”等。翻译APP获取阅读APP的显示截图,根据显示截图得到翻译结果,从而刷新显示。As another non-limiting example, the tablet computer receives a preset voice control operation of the user's voice input, such as the user's voice input "refresh translation" or "refresh translation result". The translation APP obtains the display screenshot of the reading APP, and obtains the translation result according to the display screenshot, thereby refreshing the display.
作为本申请另一实施例,如图8所示,在图3A所示实施例的基础上,本申请实施例在步骤S350之后还包括步骤S810至S820。As another embodiment of the present application, as shown in FIG. 8 , on the basis of the embodiment shown in FIG. 3A , the embodiment of the present application further includes steps S810 to S820 after step S350 .
S810,接收到用户在阅读APP中输入的用户操作。S810, a user operation input by the user in the reading APP is received.
S820,响应于该用户操作,若翻译APP确定阅读APP显示新文本,则针对阅读APP上显示的新文本进行翻译,并刷新显示。S820, in response to the user operation, if the translation APP determines that the reading APP displays new text, translate the new text displayed on the reading APP, and refresh the display.
在实际生活中,虽然阅读APP在显示文档时通常会具备翻页功能,但是翻页事件可以不由滑动操作来触发。因此,区别于图6A和图7A所示实施例,在本申请实施例中,翻译APP在系统注册了全屏用户操作事件监听。应用程序框架层的输入事件管理器可以向翻译APP提供全屏用户操作事件监听。In real life, although a reading APP usually has a page-turning function when displaying a document, the page-turning event may not be triggered by a sliding operation. Therefore, different from the embodiments shown in FIG. 6A and FIG. 7A , in this embodiment of the present application, the translation APP registers a full-screen user operation event monitoring in the system. The input event manager of the application framework layer can provide full-screen user operation event monitoring to the translation APP.
平板电脑接收到用户在阅读APP显示界面输入的用户操作,翻译APP获取阅读APP当前的显示截图。将当前的显示截图与历史的显示截图进行比对,根据比对结果判断阅读APP是否显示新文本。若确定阅读APP显示新文本,则针对阅读APP上显示的新文本进行翻译,并刷新显示;若确定阅读APP未显示新文本,则不再对当前的显示截图进行翻译,也不刷新显示。翻译APP刷新显示的流程与图3A所示实施例的步骤S350中显示翻译结果的流程相似,区别在于触发的条件不同,此处不再赘述。The tablet computer receives the user operation input by the user on the display interface of the reading APP, and translates the APP to obtain the current display screenshot of the reading APP. Compare the current display screenshot with the historical display screenshot, and judge whether the reading APP displays new text according to the comparison result. If it is determined that the reading APP displays new text, the new text displayed on the reading APP will be translated and the display will be refreshed; if it is determined that the reading APP does not display new text, the current display screenshot will not be translated and the display will not be refreshed. The process of refreshing and displaying the translation APP is similar to the process of displaying the translation result in step S350 of the embodiment shown in FIG. 3A , and the difference lies in the different triggering conditions, which will not be repeated here.
需要说明的是,历史的显示截图可为翻译APP上一次获取的阅读APP的显示截图。将当前的显示截图与历史的显示截图进行比对的过程中,可以采用全局或局部的比对方案,本申请对此不予限制。It should be noted that the display screenshot of the history may be the display screenshot of the reading APP obtained last time by the translation APP. In the process of comparing the current display screenshot with the historical display screenshot, a global or local comparison scheme may be adopted, which is not limited in this application.
本申请实施例也可以实现文本内容与翻译结果同时显示,相较于图6A所示实施例,不再监听特定的滑动翻页事件,使得本申请实施例适用更多应用场景,更具普适性;相较于图7A所示实施例,减少了用户操作,减小了交互成本。The embodiment of the present application can also realize the simultaneous display of the text content and the translation result. Compared with the embodiment shown in FIG. 6A , the specific sliding page-turning event is no longer monitored, so that the embodiment of the present application is applicable to more application scenarios and is more universal. Compared with the embodiment shown in FIG. 7A , user operations are reduced, and interaction costs are reduced.
参见图9A所示,为本申请一实施例提供的一种翻译结果显示方法的流程示意图。本实施例提供的翻译结果显示方法涉及跨设备的连接场景,当第一电子设备跨设备连接到第二电子设备时,可以在第二电子设备上显示第一电子设备显示内容的翻译结果。为了方便描述本实施例,如图9B所示,为本实施例的一示例性应用场景。在该示例性应用场景中,以手机作为第一电子设备的示例,以平板电脑作为第二电子设备的示例。Referring to FIG. 9A , it is a schematic flowchart of a method for displaying translation results according to an embodiment of the present application. The translation result display method provided in this embodiment involves a cross-device connection scenario. When a first electronic device is connected to a second electronic device across devices, the translation result of the content displayed by the first electronic device can be displayed on the second electronic device. For the convenience of describing this embodiment, as shown in FIG. 9B , an exemplary application scenario of this embodiment is shown. In this exemplary application scenario, a mobile phone is used as an example of the first electronic device, and a tablet computer is used as an example of the second electronic device.
如图9A所示,一种翻译结果显示方法包括步骤S910至S950。应理解,本实施例中与前述实施例相同的步骤,请参见前述实施例的相应描述,此处不再赘述。As shown in FIG. 9A, a translation result display method includes steps S910 to S950. It should be understood that for the steps in this embodiment that are the same as those in the foregoing embodiments, please refer to the corresponding descriptions of the foregoing embodiments, and details are not repeated here.
S910,手机接收到用户开启阅读APP的操作,打开阅读APP。S910, the mobile phone receives the operation of the user to open the reading APP, and opens the reading APP.
S920,手机响应于监听到的手势事件,触发系统弹框,所述系统弹框为询问用户是否进入同步翻译状态的系统弹框。S920, the mobile phone triggers a system pop-up frame in response to the monitored gesture event, where the system pop-up frame is a system pop-up frame that asks the user whether to enter a synchronous translation state.
在本申请一非限制性示例中,继续参见图9B所示,手势事件为三指捏合事件。手机响应于三指捏合事件,触发系统弹框。In a non-limiting example of the present application, continuing to refer to FIG. 9B , the gesture event is a three-finger pinch event. The mobile phone triggers the system popup in response to the three-finger pinch event.
更一般地,如前所述,在本申请一些实施例中,触发系统弹框的用户操作可以包括:预设语音的语音控制操作,或预设手势触摸操作,或预设光标控制操作等。More generally, as described above, in some embodiments of the present application, the user operation that triggers the system pop-up frame may include: a preset voice voice control operation, a preset gesture touch operation, or a preset cursor control operation, and the like.
S930,手机接收到用户输入的确认操作,显示设备列表。S930, the mobile phone receives the confirmation operation input by the user, and displays the device list.
在本申请一些实施例中,设备列表可以包括本机和/或周边的可接收电子设备。In some embodiments of the present application, the device list may include receivable electronic devices of the local machine and/or surrounding areas.
在本申请其他一些实施例中,设备列表可以包括本机和/或周边具备显示屏的可接收电子设备。In some other embodiments of the present application, the device list may include the device and/or the receivable electronic device with a display screen around it.
在本申请一非限制性示例中,继续参见图9B所示,手机响应于用户点击“是”控件的操作,显示设备列表。In a non-limiting example of the present application, continuing to refer to Fig. 9B, the mobile phone displays a device list in response to the user's operation of clicking the "Yes" control.
应理解,在本申请一些实施例中,手机与周边可接收设备建立连接的流程可以包括:发现和连接等步骤,或,发现、认证和连接等步骤。It should be understood that, in some embodiments of the present application, the process of establishing a connection between a mobile phone and a peripheral receivable device may include steps such as discovery and connection, or steps such as discovery, authentication and connection.
在本申请一些实施例中,手机可以通过BT模块、NFC模块或Wi-Fi模块等,搜索周边的可接收设备,然后显示可接收设备的设备列表。当接收到用户在设备列表中选定一目标设备,例如平板电脑,作为翻译结果的显示设备后,可以建立手机与平板电脑之间的Wi-Fi直连、热点、或超宽带(ultra-wideband,UWB)等无线通信连接。最后,通过建立的无线通信连接在手机与平板电脑间实现控制信息和/或数据信息等的传输。需要说明的是,在其他情形下,电子设备间还可以建立依赖USB数据线等的有线连接以实现信息传输。或者,电子设备间还可以通过扫码建立无线通信连接以实现信息传输。应理解,本申请实施例对电子设备间建立无线或有线通信连接的方式不做具体限定,任何实现跨设备连接的方式都可以用于本申请。In some embodiments of the present application, the mobile phone may search for nearby receivable devices through a BT module, an NFC module, or a Wi-Fi module, etc., and then display a device list of the receivable devices. After receiving that the user selects a target device in the device list, such as a tablet computer, as the display device of the translation result, a Wi-Fi direct connection, a hotspot, or an ultra-wideband (ultra-wideband) connection between the mobile phone and the tablet computer can be established. , UWB) and other wireless communication connections. Finally, the transmission of control information and/or data information and the like is realized between the mobile phone and the tablet computer through the established wireless communication connection. It should be noted that, in other situations, a wired connection relying on a USB data cable or the like may also be established between the electronic devices to realize information transmission. Alternatively, a wireless communication connection can also be established between electronic devices by scanning a code to realize information transmission. It should be understood that the embodiments of the present application do not specifically limit the manner of establishing a wireless or wired communication connection between electronic devices, and any manner of implementing a cross-device connection can be used in the present application.
S940,手机接收到用户在所述设备列表中选择平板电脑的点击操作,建立与平板电脑之间的通信连接,所述平板电脑为所述设备列表中的设备。S940, the mobile phone receives a click operation of the user selecting a tablet computer in the device list, and establishes a communication connection with the tablet computer, where the tablet computer is a device in the device list.
S950,在平板电脑显示所述手机的阅读APP中显示内容的翻译结果。S950, displaying the translation result of the content displayed in the reading APP of the mobile phone on the tablet computer.
手机接收到用户输入的选择平板电脑的点击操作后,手机与平板电脑建立连接。手机获取阅读APP中的当前显示内容,在平板电脑显示手机的阅读APP中当前显示内容的翻译结果。After the mobile phone receives the click operation of selecting the tablet computer input by the user, the mobile phone establishes a connection with the tablet computer. The mobile phone obtains the currently displayed content in the reading APP, and displays the translation result of the currently displayed content in the reading APP of the mobile phone on the tablet computer.
在本申请一些实施例中,在手机接收到用户输入的选择平板电脑的点击操作后,手机与平板电脑建立通信连接。在一些实施例中,基于两者建立的通信连接实现两者信息交互,手机可以获取平板电脑的设备能力,确定平板电脑是否具备翻译功能。In some embodiments of the present application, after the mobile phone receives a click operation input by the user to select the tablet computer, the mobile phone establishes a communication connection with the tablet computer. In some embodiments, the information exchange between the two is realized based on the communication connection established by the two, and the mobile phone can obtain the device capability of the tablet computer to determine whether the tablet computer has the translation function.
在一些实际场景中,平板电脑具备翻译功能。In some real-world scenarios, the tablet has translation capabilities.
在一些实现方式中,在手机与平板电脑建立连接后,手机将同步翻译指令发送给平板电脑,平板电脑根据接收到的同步翻译指令启动翻译APP。翻译APP可以供用户输入源语言和/或目标语言,当获取到用户在平板电脑输入的源语言和/或目标语言,平板电脑发送语言确定指令给手机。手机接收到语言确定指令后,获取阅读APP的显示截图,通过手机与平板电脑之间建立的连接,将显示截图发送给平板电脑。平板电脑获取显示截图,提取该显示截图中的文字信息,在将文字信息翻译成对应的语言后,在自身的显示屏中显示翻译结果。In some implementations, after the mobile phone and the tablet computer are connected, the mobile phone sends the synchronous translation instruction to the tablet computer, and the tablet computer starts the translation APP according to the received synchronous translation instruction. The translation APP can allow the user to input the source language and/or the target language. When the source language and/or the target language input by the user on the tablet computer is obtained, the tablet computer sends a language determination instruction to the mobile phone. After the mobile phone receives the language determination instruction, it obtains the display screenshot of the reading APP, and sends the display screenshot to the tablet computer through the connection established between the mobile phone and the tablet computer. The tablet computer obtains a display screenshot, extracts the text information in the display screenshot, and after translating the text information into a corresponding language, displays the translation result on its own display screen.
在另一些实现方式中,翻译APP不需要用户输入源语言和/或目标语言,翻译APP可以识别阅读APP显示内容的语言作为源语言,可以根据用户历史使用习惯确定目标语言。手机获取阅读APP的显示截图,通过手机与平板电脑之间建立的通信连接,将显示截图发送给平板电脑。平板电脑获取显示截图,提取该显示截图中的文字信息,在将文字信息翻译成对应的目标语言后,在自身的显示屏中显示翻译结果。In other implementations, the translation APP does not require the user to input the source language and/or the target language, the translation APP can identify the language in which the displayed content of the reading APP is read as the source language, and the target language can be determined according to the user's historical usage habits. The mobile phone obtains the display screenshot of the reading APP, and sends the display screenshot to the tablet computer through the communication connection established between the mobile phone and the tablet computer. The tablet computer obtains a display screenshot, extracts the text information in the display screenshot, and after translating the text information into the corresponding target language, displays the translation result on its own display screen.
在这些实际场景中,平板电脑具备翻译功能。应理解,在这些实际场景中,若手机具备翻译功能,也可以在手机侧对阅读APP的显示内容进行翻译得到翻译结果后,再在平板电脑显示翻译结果。当得到翻译结果的过程在手机上进行时,手机通过与平板电脑之间建立的通信连接,将翻译结果发送给平板电脑。还应理解,对阅读APP的显示内容进行翻译得到翻译结果的过程,可以部分在手机进行,部分在平板电脑进行。本申请对此过程的执行主体不予限制。In these real-world scenarios, the tablet has translation capabilities. It should be understood that in these actual scenarios, if the mobile phone has a translation function, the displayed content of the reading APP can also be translated on the mobile phone side to obtain the translation result, and then the translation result can be displayed on the tablet computer. When the process of obtaining the translation result is performed on the mobile phone, the mobile phone sends the translation result to the tablet computer through the communication connection established between the mobile phone and the tablet computer. It should also be understood that the process of translating the displayed content of the reading APP to obtain the translation result may be partially performed on a mobile phone and partially performed on a tablet computer. This application does not limit the executive body of this process.
可选地,在这些实际场景所展示的实现方式的基础上,在本申请其他一些实现方式中,平板电脑可以刷新显示,即刷新显示翻译结果。可以自动或人工实现翻译结果的刷新。Optionally, based on the implementation manners shown in these actual scenarios, in some other implementation manners of the present application, the tablet computer may refresh the display, that is, refresh and display the translation result. The refresh of translation results can be achieved automatically or manually.
在一些实现方式中,手机接收到用户在阅读APP中输入的滑动操作,所述滑动操作为滑动翻页操作。手机响应于该滑动操作,在阅读APP的显示界面更新显示内容。平板电脑显示阅读APP更新后的显示内容的翻译结果。In some implementations, the mobile phone receives a sliding operation input by the user in the reading APP, where the sliding operation is a sliding page turning operation. In response to the sliding operation, the mobile phone updates the display content on the display interface of the reading APP. The tablet computer displays the translation result of reading the updated display content of the APP.
作为一非限制性示例,系统监听阅读APP的滑动事件,响应于用户输入的滑动事件,例如手指向上滑动,阅读APP更新显示内容,显示下一页。平板电脑显示阅读APP更新后的显示内容的翻译结果。得到翻译结果的过程可以在手机或平板电脑上进行。As a non-limiting example, the system monitors the sliding event of the reading APP, and in response to the sliding event input by the user, such as sliding a finger upward, the reading APP updates the displayed content and displays the next page. The tablet computer displays the translation result of reading the updated display content of the APP. The process of getting the translation results can be done on a mobile phone or tablet.
在另一些实现方式中,手机接收到用户输入的刷新翻译操作,手机响应于所述刷新翻译操作,获取阅读APP当前显示内容,并指示平板电脑显示阅读APP当前显示内容的翻译结果。In other implementations, the mobile phone receives a refresh translation operation input by the user, and in response to the refresh translation operation, the mobile phone obtains the current display content of the reading APP, and instructs the tablet computer to display the translation result of the currently displayed content of the reading APP.
作为一非限制性示例,不管手机阅读APP的显示界面的显示内容是否更新,手机监听到用户语音输入的“刷新翻译结果”,控制平板电脑显示阅读APP当前显示内容对应的翻译结果。具体地,手机获取阅读APP当前的显示截图,然后在手机或平板电脑提取当前显示截图的文本信息,对文本信息进行翻译得到翻译结果,最后在平板电脑显示翻译结果。As a non-limiting example, regardless of whether the display content of the display interface of the mobile phone reading APP is updated, the mobile phone monitors the "refresh translation result" input by the user's voice, and controls the tablet computer to display the translation result corresponding to the currently displayed content of the reading APP. Specifically, the mobile phone obtains the current display screenshot of the reading APP, then extracts the text information of the currently displayed screenshot on the mobile phone or tablet computer, translates the text information to obtain the translation result, and finally displays the translation result on the tablet computer.
在另一些实现方式中,平板电脑接收到用户输入的刷新翻译操作,响应于所述刷新翻译操作,发送刷新翻译指示给手机,手机根据刷新翻译指示获取阅读APP当前显示内容,并指示平板电脑显示阅读APP当前显示内容的翻译结果。In other implementations, the tablet computer receives a refresh translation operation input by the user, and in response to the refresh translation operation, sends a refresh translation instruction to the mobile phone, and the mobile phone obtains the current display content of the reading APP according to the refresh translation instruction, and instructs the tablet computer to display Read the translation result of the content currently displayed in the APP.
作为一非限制性示例,不管手机阅读APP的显示界面的显示内容是否更新,平板电脑监听到用户点击翻译APP显示界面的“刷新”控件,平板电脑获取阅读APP当前显示内容对应的翻译结果,并显示翻译结果。示例性地,平板电脑监听到用户点击翻译APP显示界面的“刷新”控件,发送阅读APP当前显示截图获取请求到手机,手机响应于该获取请求,获取阅读APP当前的显示截图,然后将显示截图反馈给平板电脑。平板电脑提取当前显示截图的文本信息,对文本信息进行翻译得到翻译结果,最后在平板电脑显示翻译结果。应理解,在其他示例中,提取文本信息的过程,和/或,对文本信息进行翻译得到翻译结果的过程,可以在手机上进行。As a non-limiting example, regardless of whether the display content of the display interface of the mobile phone reading APP is updated, the tablet computer detects that the user clicks the "refresh" control of the display interface of the translation APP, and the tablet computer obtains the translation result corresponding to the current display content of the reading APP, and Display the translation result. Exemplarily, the tablet computer detects that the user clicks on the "refresh" control of the display interface of the translation APP, and sends a request for obtaining a screenshot of the current display of the reading APP to the mobile phone, and the mobile phone responds to the obtaining request, obtains the current display screenshot of the reading APP, and then displays the screenshot. Feedback to tablet. The tablet computer extracts the text information currently displayed in the screenshot, translates the text information to obtain the translation result, and finally displays the translation result on the tablet computer. It should be understood that, in other examples, the process of extracting text information, and/or the process of translating text information to obtain a translation result, may be performed on a mobile phone.
在另一些实现方式中,手机接收到用户在阅读APP中输入的用户操作;手机响应于该用户操作,判断阅读APP是否更新了显示内容,若阅读APP更新了显示内容,则获取阅读APP更新后的显示内容,并指示平板电脑显示所述阅读APP更新后的显示内容的翻译结果;若阅读APP未更新显示内容,则不执行响应。In other implementation manners, the mobile phone receives a user operation input by the user in the reading APP; the mobile phone determines whether the reading APP has updated the display content in response to the user operation, and if the reading APP has updated the display content, obtains the updated content of the reading APP. and instructs the tablet computer to display the translation result of the updated display content of the reading APP; if the reading APP does not update the display content, no response is executed.
作为一非限制性示例,手机监听阅读APP的任一用户操作,响应于用户输入的任一用户操作,判断阅读APP是否更新了显示内容页。若阅读APP更新了显示内容,则获取阅读APP更新后的显示内容,并指示平板电脑显示阅读APP更新后的显示内容的翻译结果。As a non-limiting example, the mobile phone monitors any user operation of the reading APP, and in response to any user operation input by the user, determines whether the reading APP has updated the displayed content page. If the reading APP updates the display content, obtain the updated display content of the reading APP, and instruct the tablet computer to display the translation result of the updated display content of the reading APP.
在其他一些实际场景中,平板电脑不具备翻译功能。应理解,在这些实际场景下,手机具备翻译功能,手机调用平板电脑的显示功能。In some other practical scenarios, the tablet does not have translation capabilities. It should be understood that in these actual scenarios, the mobile phone has a translation function, and the mobile phone invokes the display function of the tablet computer.
在一些实现方式中,在手机与平板电脑建立连接后,手机启动翻译APP。翻译APP可以供用户输入源语言和/或目标语言。当获取到用户输入的源语言和/或目标语言后,手机获取阅读APP的显示截图。手机提取该显示截图中的文字信息,在将文字信息翻译成对应的语言后,通过手机与平板电脑之间建立的连接,将翻译结果发送给平板电脑。平板电脑在自身的显示屏中显示翻译结果。应理解,在这些实现方式中,手机上翻译APP的显示界面可以与阅读APP的显示界面同时显示,翻译APP设置有供用户输入源语言和目标语言的控件。控件可以包括选择控件或输入框控件等。In some implementations, after the mobile phone establishes a connection with the tablet computer, the mobile phone starts the translation APP. The translation APP can allow the user to input the source language and/or the target language. After obtaining the source language and/or target language input by the user, the mobile phone obtains a display screenshot of the reading APP. The mobile phone extracts the text information in the displayed screenshot, and after translating the text information into the corresponding language, the translation result is sent to the tablet computer through the connection established between the mobile phone and the tablet computer. The tablet displays the translation results in its own display. It should be understood that, in these implementation manners, the display interface of the translation APP on the mobile phone may be displayed simultaneously with the display interface of the reading APP, and the translation APP is provided with controls for the user to input the source language and the target language. Controls can include selection controls or input box controls.
在另一些实现方式中,翻译APP不需要用户输入源语言和目标语言,翻译APP识别阅读APP显示内容的语言作为源语言,根据用户历史使用习惯确定目标语言。手机获取阅读APP的显示截图。手机提取该显示截图中的文字信息,在将文字信息翻译成对应的语言后,通过手机与平板电脑之间建立的连接,将翻译结果发送给平板电脑。平板电脑在自身的显示屏中显示翻译结果。应理解,手机上翻译APP可以不进行显示,在后台运行。In other implementations, the translation APP does not require the user to input the source language and the target language, the translation APP recognizes the language in which the displayed content of the APP is read as the source language, and determines the target language according to the user's historical usage habits. The mobile phone obtains the display screenshot of the reading APP. The mobile phone extracts the text information in the displayed screenshot, and after translating the text information into the corresponding language, the translation result is sent to the tablet computer through the connection established between the mobile phone and the tablet computer. The tablet displays the translation results in its own display. It should be understood that the translation APP on the mobile phone may not be displayed and run in the background.
在跨设备连接场景的实施例中,可以根据平板电脑的能力,确定在手机或/平板电脑进行翻译以得到翻译结果,再在平板电脑显示翻译结果。基于跨设备连接场景实现本申请的技术方案,一个设备显示阅读内容,另一个设备同步显示翻译结果,一方面,扩展了本申请实施例的使用场景,大大提高了本申请实施例的环境适应性;另一方面,两个设备的显示屏得到充分利用,提高了用户阅读效率。In the embodiment of the cross-device connection scenario, according to the capabilities of the tablet computer, it may be determined to perform translation on the mobile phone or/tablet computer to obtain the translation result, and then display the translation result on the tablet computer. The technical solution of the present application is implemented based on a cross-device connection scenario. One device displays the reading content, and the other device synchronously displays the translation result. On the one hand, the usage scenarios of the embodiments of the present application are expanded, and the environmental adaptability of the embodiments of the present application is greatly improved. ; On the other hand, the display screens of the two devices are fully utilized, improving the user's reading efficiency.
可选地,在本申请其他一些实施例中,手机监听到手势事件等之后,可以显示设备列表。在这些实施例中,可以不用触发系统弹框,也不用接收用户输入的确认操作。简化了用户操作,减小了用户交互成本。Optionally, in some other embodiments of the present application, the mobile phone may display a device list after monitoring a gesture event or the like. In these embodiments, it is not necessary to trigger the system pop-up box, nor to receive a confirmation operation input by the user. User operations are simplified and user interaction costs are reduced.
可选地,在本申请其他一些实施例中,手机和平板电脑可以预先建立通信连接,在这种情形下,手机监听到手势事件后,获取阅读APP当前显示内容,指示平板电脑显示阅读APP当前显示内容的翻译结果。Optionally, in some other embodiments of the present application, the mobile phone and the tablet computer may establish a communication connection in advance. In this case, after the mobile phone monitors the gesture event, it obtains the current display content of the reading APP, and instructs the tablet computer to display the current content of the reading APP. Displays the translation result of the content.
可选地,在本申请其他一些实施例中,手机监听到手势事件等之后,可以根据历史连接记录,建立与平板电脑的通信连接。既而,手机将阅读APP的待翻译内容或翻译结果发送给平板电脑,平板电脑将待翻译内容翻译成目标语言后显示,或接收到翻译结果后显示翻译结果。Optionally, in some other embodiments of the present application, after the mobile phone monitors gesture events, etc., it can establish a communication connection with the tablet computer according to the historical connection record. Then, the mobile phone sends the content to be translated or the translation result of the reading APP to the tablet computer, and the tablet computer translates the content to be translated into the target language and displays it, or displays the translation result after receiving the translation result.
可选地,在本申请其他一些实施例中,用户可以在设备列表中选择本机,即手机。应理解,在这些实际场景下,手机具备翻译功能。手机接收到用户在设备列表中选择本机的点击操作后,启动翻译APP,显示翻译APP的显示界面,翻译APP的显示界面与阅读APP的显示界面同时显示。在翻译APP的显示界面显示针对阅读APP的显示内容的翻译结果。应理解,这些实施例与前述不涉及跨设备连接的实施例相同,此处不再赘述。Optionally, in some other embodiments of the present application, the user may select a local machine, that is, a mobile phone, in the device list. It should be understood that in these actual scenarios, the mobile phone has a translation function. After the mobile phone receives the user's click operation of selecting the device in the device list, the translation APP is started, and the display interface of the translation APP is displayed, and the display interface of the translation APP and the display interface of the reading APP are displayed at the same time. The translation result for the displayed content of the reading APP is displayed on the display interface of the translation APP. It should be understood that these embodiments are the same as the foregoing embodiments that do not involve cross-device connection, and are not repeated here.
可选地,在本申请其他一些实施例中,手机可以与多个平板电脑建立通信连接,从而可以与多个平板电脑进行数据交互,在多个平板电脑上显示翻译结果。需要说明的是,在一些实现方式中,根据用户历史使用习惯或用户输入的不同目标语言等,可以在不同平板电脑显示不同目标语言的翻译结果。Optionally, in some other embodiments of the present application, the mobile phone can establish a communication connection with multiple tablet computers, so as to perform data interaction with the multiple tablet computers, and display the translation results on the multiple tablet computers. It should be noted that, in some implementation manners, translation results in different target languages may be displayed on different tablet computers according to the user's historical usage habits or different target languages input by the user.
对应于上文实施例所述翻译结果显示方法,本申请实施例还提供了一种翻译结果显示装置,翻译结果显示装置的各个模块可以对应实现翻译结果显示方法的各个步骤。Corresponding to the translation result display method described in the above embodiment, the embodiment of the present application further provides a translation result display device, and each module of the translation result display device can correspond to each step of the translation result display method.
需要说明的是,模块/单元之间的信息交互、执行过程等内容,由于与本申请方法实施例基于同一构思,其具体功能及带来的技术效果,具体可参见方法实施例部分,此处不再赘述。It should be noted that the information exchange, execution process and other contents between modules/units are based on the same concept as the method embodiments of the present application. For specific functions and technical effects, please refer to the method embodiments section, here No longer.
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。上述系统中单元、模块的具体工作过程,可以参考前述方法实施例中的 对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. Module completion, that is, dividing the internal structure of the device into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment may be integrated in one processing unit, or each unit may exist physically alone, or two or more units may be integrated in one unit, and the above-mentioned integrated units may adopt hardware. It can also be realized in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing from each other, and are not used to limit the protection scope of the present application. For the specific working processes of the units and modules in the above system, reference may be made to the corresponding processes in the foregoing method embodiments, and details are not repeated here.
本申请实施例还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现可实现上述各个方法实施例中的步骤。Embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the steps in the foregoing method embodiments can be implemented.
本申请实施例提供了一种计算机程序产品,当计算机程序产品在电子设备上运行时,使得电子设备执行时实现可实现上述各个方法实施例中的步骤。The embodiments of the present application provide a computer program product, when the computer program product runs on an electronic device, the steps in the foregoing method embodiments can be implemented when the electronic device executes.
所述集成的模块/单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请实现上述实施例方法中的全部或部分流程,可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质至少可以包括:能够将计算机程序代码携带到拍照装置/电子设备的任何实体或装置、记录介质、计算机存储器、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、电载波信号、电信信号以及软件分发介质。例如U盘、移动硬盘、磁碟或者光盘等。在某些司法管辖区,根据立法和专利实践,计算机可读介质不可以是电载波信号和电信信号。The integrated modules/units, if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium. Based on this understanding, the present application realizes all or part of the processes in the methods of the above embodiments, which can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium. When executed by a processor, the steps of each of the above method embodiments can be implemented. Wherein, the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form, and the like. The computer-readable medium may include at least: any entity or device capable of carrying the computer program code to the photographing device/electronic device, recording medium, computer memory, read-only memory (ROM), random access memory (Random Access Memory, RAM), electrical carrier signals, telecommunication signals, and software distribution media. For example, U disk, mobile hard disk, disk or CD, etc. In some jurisdictions, under legislation and patent practice, computer readable media may not be electrical carrier signals and telecommunications signals.
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参见其它实施例的相关描述。In the foregoing embodiments, the description of each embodiment has its own emphasis. For parts that are not described or described in detail in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Skilled artisans may implement the described functionality using different methods for each particular application, but such implementations should not be considered beyond the scope of this application.
在本申请所提供的实施例中,应该理解到,所揭露的电子设备和方法,可以通过其它的方式实现。例如,以上所描述的电子设备实施例仅仅是示意性的。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。In the embodiments provided in this application, it should be understood that the disclosed electronic devices and methods may be implemented in other manners. For example, the electronic device embodiments described above are merely illustrative. On the other hand, the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。The above-mentioned embodiments are only used to illustrate the technical solutions of the present application, but not to limit them; although the present application has been described in detail with reference to the above-mentioned embodiments, those of ordinary skill in the art should understand that: it can still be used for the above-mentioned implementations. The technical solutions described in the examples are modified, or some technical features thereof are equivalently replaced; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions in the embodiments of the application, and should be included in the within the scope of protection of this application.

Claims (21)

  1. 一种翻译结果显示方法,其特征在于,包括:A method for displaying translation results, comprising:
    响应于用户在第一应用中输入的第一操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上,所述第二应用为翻译应用;In response to the first operation input by the user in the first application, the display interface of the first application and the display interface of the second application are displayed in a split screen; or, the display interface of the second application is superimposed and displayed on the On the display interface of the first application, the second application is a translation application;
    将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果;Translating the currently displayed content in the first application into a target language to obtain a translation result;
    在所述第二应用的显示界面显示所述翻译结果。The translation result is displayed on the display interface of the second application.
  2. 根据权利要求1所述的方法,其特征在于,所述响应于用户在第一应用中输入的第一操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上,包括:The method according to claim 1, wherein the display interface of the first application and the display interface of the second application are displayed in a split screen in response to the first operation input by the user in the first application; Or, superimposing and displaying the display interface of the second application on the display interface of the first application, including:
    响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;In response to the first operation input by the user in the first application, a system pop-up box is triggered, and the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
    若接收到用户针对所述系统弹框输入的确认操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上。If the user's confirmation operation for the system pop-up box input is received, the display interface of the first application and the display interface of the second application are displayed in a split screen; or, the display interface of the second application is superimposed and displayed on the on the display interface of the first application.
  3. 根据权利要求1或2所述的方法,其特征在于,在所述将所述第一应用中的显示内容翻译成目标语言,获得翻译结果之前,还包括:The method according to claim 1 or 2, characterized in that, before translating the displayed content in the first application into a target language and obtaining a translation result, the method further comprises:
    获取用户在所述第二应用中输入的源语言和/或目标语言。Obtain the source language and/or target language input by the user in the second application.
  4. 根据权利要求1或2所述的方法,其特征在于,所述在所述第二应用的显示界面显示所述翻译结果之后,还包括:The method according to claim 1 or 2, wherein after displaying the translation result on the display interface of the second application, the method further comprises:
    当接收到用户输入的更新所述第一应用当前显示内容的第二操作后,响应于所述第二操作,在所述第一应用的显示界面显示更新后的显示内容,并在所述第二应用的显示界面显示所述更新后的显示内容对应的翻译结果。After receiving a second operation input by the user to update the current display content of the first application, in response to the second operation, display the updated display content on the display interface of the first application, and display the updated display content in the first application. The display interface of the second application displays the translation result corresponding to the updated display content.
  5. 根据权利要求1或2所述的方法,其特征在于,所述在所述第二应用的显示界面显示所述翻译结果之后,还包括:The method according to claim 1 or 2, wherein after displaying the translation result on the display interface of the second application, the method further comprises:
    接收用户输入的刷新翻译操作;Receive a refresh translation operation entered by the user;
    响应于所述刷新翻译操作,在所述第二应用的显示界面,显示所述第一应用的显示界面当前显示内容的翻译结果。In response to the refreshing translation operation, a translation result of the content currently displayed on the display interface of the first application is displayed on the display interface of the second application.
  6. 根据权利要求1或2所述的方法,其特征在于,所述在所述第二应用的显示界面显示所述翻译结果之后,还包括:The method according to claim 1 or 2, wherein after displaying the translation result on the display interface of the second application, the method further comprises:
    接收用户在所述第一应用中输入的第二操作;receiving a second operation input by the user in the first application;
    响应于所述第二操作,若在所述第一应用的显示界面更新了显示内容,则在所述第二应用的显示界面显示更新后的显示内容对应的翻译结果。In response to the second operation, if the display content is updated on the display interface of the first application, a translation result corresponding to the updated display content is displayed on the display interface of the second application.
  7. 根据权利要求1或2所述的方法,其特征在于,在分屏显示所述第一应用的显示界面和所述第二应用的显示界面的情形下,所述方法还包括:The method according to claim 1 or 2, wherein, in the case of displaying the display interface of the first application and the display interface of the second application in a split screen, the method further comprises:
    响应于用户在所述第一应用的显示界面或所述第二应用的显示界面输入的第四操作,所述第一应用的显示界面或所述第二应用的显示界面切换为悬浮窗;In response to a fourth operation input by the user on the display interface of the first application or the display interface of the second application, the display interface of the first application or the display interface of the second application is switched to a floating window;
    在将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上的情形下,所述方法还包括:In the case of superimposing and displaying the display interface of the second application on the display interface of the first application, the method further includes:
    响应于用户在所述第二应用的显示界面输入的第五操作,所述第一应用的显示界面和所述第二 应用的显示界面切换为分屏显示。In response to the fifth operation input by the user on the display interface of the second application, the display interface of the first application and the display interface of the second application are switched to split-screen display.
  8. 一种翻译结果显示方法,其特征在于,包括:A method for displaying translation results, comprising:
    第一电子设备响应于用户在第一应用中输入的第一操作,将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果;The first electronic device, in response to the first operation input by the user in the first application, translates the currently displayed content in the first application into the target language, and obtains a translation result;
    所述第一电子设备将所述翻译结果发送给与所述第一电子设备通信连接的第二电子设备进行显示。The first electronic device sends the translation result to a second electronic device communicatively connected to the first electronic device for display.
  9. 根据权利要求8所述的方法,其特征在于,所述第一电子设备响应于用户在第一应用中输入的第一操作,将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果,包括:The method according to claim 8, wherein, in response to a first operation input by a user in the first application, the first electronic device translates the currently displayed content in the first application into a target language, and obtains Translation results, including:
    第一电子设备响应于用户在第一应用中输入的第一操作,显示设备列表;The first electronic device displays a device list in response to a first operation input by the user in the first application;
    所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
    所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
  10. 根据权利要求8所述的方法,其特征在于,所述第一电子设备响应于用户在第一应用中输入的第一操作,将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果,包括:The method according to claim 8, wherein, in response to a first operation input by a user in the first application, the first electronic device translates the currently displayed content in the first application into a target language, and obtains Translation results, including:
    第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
    若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,建立与第二电子设备之间的通信连接;If the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
    所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the content currently displayed in the first application into a target language to obtain a translation result.
  11. 根据权利要求8所述的方法,其特征在于,所述第一电子设备响应于用户在第一应用中输入的第一操作,将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果,包括:The method according to claim 8, wherein, in response to a first operation input by a user in the first application, the first electronic device translates the currently displayed content in the first application into a target language, and obtains Translation results, including:
    第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
    若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,显示设备列表;If the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list;
    所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
    所述第一电子设备将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果。The first electronic device translates the currently displayed content in the first application into a target language to obtain a translation result.
  12. 一种翻译结果显示方法,其特征在于,包括:A method for displaying translation results, comprising:
    第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容;The first electronic device, in response to a first operation input by the user in the first application, acquires the currently displayed content in the first application;
    所述第一电子设备将所述当前显示内容发送给与所述第一电子设备通信连接的第二电子设备,并指示所述第二电子设备将所述显示内容翻译成目标语言后进行显示。The first electronic device sends the currently displayed content to a second electronic device communicatively connected to the first electronic device, and instructs the second electronic device to translate the displayed content into a target language and display it.
  13. 根据权利要求12所述的方法,其特征在于,所述第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容,包括:The method according to claim 12, wherein, in response to a first operation input by a user in the first application, the first electronic device acquires the currently displayed content in the first application, comprising:
    第一电子设备响应于用户在第一应用中输入的第一操作,显示设备列表;The first electronic device displays a device list in response to a first operation input by the user in the first application;
    所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
    所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires currently displayed content in the first application.
  14. 根据权利要求12所述的方法,其特征在于,所述第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容,包括:The method according to claim 12, wherein, in response to a first operation input by a user in the first application, the first electronic device acquires the currently displayed content in the first application, comprising:
    第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
    若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,建立与第二电子设备之间的通信连接;If the first electronic device receives the confirmation operation input by the user for the system pop-up box, establish a communication connection with the second electronic device;
    所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires the currently displayed content in the first application.
  15. 根据权利要求12所述的方法,其特征在于,所述第一电子设备响应于用户在第一应用中输入的第一操作,获取所述第一应用中的当前显示内容,包括:The method according to claim 12, wherein, in response to a first operation input by a user in the first application, the first electronic device acquires the currently displayed content in the first application, comprising:
    第一电子设备响应于用户在第一应用中输入的第一操作,触发系统弹框,所述系统弹框包括询问用户是否进入同步翻译状态的系统弹框;The first electronic device triggers a system pop-up box in response to the first operation input by the user in the first application, where the system pop-up box includes a system pop-up box that asks the user whether to enter the synchronous translation state;
    若所述第一电子设备接收到用户针对所述系统弹框输入的确认操作,显示设备列表;If the first electronic device receives a confirmation operation input by the user for the system pop-up box, display a device list;
    所述第一电子设备接收到用户在所述设备列表中选择第二电子设备的第二操作,建立与所述第二电子设备之间的通信连接,所述第二电子设备为所述设备列表中的设备;The first electronic device receives a second operation of the user selecting a second electronic device in the device list, and establishes a communication connection with the second electronic device, where the second electronic device is the device list equipment in;
    所述第一电子设备获取所述第一应用中的当前显示内容。The first electronic device acquires currently displayed content in the first application.
  16. 根据权利要求8至15任一项所述的方法,其特征在于,还包括:The method according to any one of claims 8 to 15, further comprising:
    所述第一电子设备接收到用户输入的更新所述第一应用当前显示内容的第二操作;receiving, by the first electronic device, a second operation input by the user for updating the content currently displayed by the first application;
    所述第一电子设备响应于所述第二操作,在所述第一应用的显示界面显示更新后的显示内容,指示所述第二电子设备显示所述更新后的显示内容对应的翻译结果。The first electronic device displays the updated display content on the display interface of the first application in response to the second operation, and instructs the second electronic device to display the translation result corresponding to the updated display content.
  17. 根据权利要求8至15任一项所述的方法,其特征在于,还包括:The method according to any one of claims 8 to 15, further comprising:
    所述第一电子设备接收到用户输入的刷新翻译操作;The first electronic device receives a refresh translation operation input by the user;
    所述第一电子设备响应于所述刷新翻译操作,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果;The first electronic device, in response to the refresh translation operation, acquires the currently displayed content in the first application, and instructs the second electronic device to display the translation result corresponding to the currently displayed content in the first application;
    或,还包括:or, also include:
    所述第一电子设备接收到来自第二电子设备的刷新翻译指示;所述刷新翻译指示由所述第二电子设备接收到用户输入的刷新翻译操作而触发;The first electronic device receives a refresh translation instruction from the second electronic device; the refresh translation instruction is triggered by the second electronic device receiving a refresh translation operation input by a user;
    所述第一电子设备响应于所述刷新翻译指示,获取所述第一应用中的当前显示内容,指示所述第二电子设备显示所述第一应用中的当前显示内容对应的翻译结果。The first electronic device, in response to the refresh translation instruction, acquires the currently displayed content in the first application, and instructs the second electronic device to display a translation result corresponding to the currently displayed content in the first application.
  18. 根据权利要求8至15任一项所述的方法,其特征在于,还包括:The method according to any one of claims 8 to 15, further comprising:
    所述第一电子设备接收到用户在所述第一应用中输入的第二操作;the first electronic device receives a second operation input by the user in the first application;
    所述第一电子设备响应于所述第二操作,若确定所述第一应用的显示界面更新了显示内容,则指示所述第二电子设备显示所述第一应用更新后的显示内容对应的翻译结果。In response to the second operation, the first electronic device instructs the second electronic device to display the content corresponding to the updated display content of the first application if it is determined that the display interface of the first application has updated the display content. translation result.
  19. 一种翻译结果显示装置,其特征在于,包括:A translation result display device, comprising:
    第一显示模块,用于响应于用户在第一应用中输入的第一操作,分屏显示所述第一应用的显示界面和所述第二应用的显示界面;或,将所述第二应用的显示界面叠加显示在所述第一应用的显示界面上,所述第二应用为翻译应用;a first display module, configured to display the display interface of the first application and the display interface of the second application in a split screen in response to a first operation input by the user in the first application; or, display the second application The display interface is superimposed and displayed on the display interface of the first application, and the second application is a translation application;
    翻译模块,用于将所述第一应用中的当前显示内容翻译成目标语言,获得翻译结果;a translation module for translating the current display content in the first application into a target language to obtain a translation result;
    第二显示模块,用于在所述第二应用的显示界面显示所述翻译结果。The second display module is configured to display the translation result on the display interface of the second application.
  20. 一种电子设备,包括显示屏、存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时,使得所述电子设备实现如权利要求1至18任一项所述的方法。An electronic device, comprising a display screen, a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that when the processor executes the computer program, all The electronic device implements the method according to any one of claims 1 to 18.
  21. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至18任一项所述的方法。A computer-readable storage medium storing a computer program, characterized in that, when the computer program is executed by a processor, the method according to any one of claims 1 to 18 is implemented.
PCT/CN2021/104070 2020-07-02 2021-07-01 Translation result display method and apparatus, and electronic device WO2022002213A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010630277.8 2020-07-02
CN202010630277.8A CN113885973B (en) 2020-07-02 2020-07-02 Translation result display method and device and electronic equipment

Publications (1)

Publication Number Publication Date
WO2022002213A1 true WO2022002213A1 (en) 2022-01-06

Family

ID=79013105

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/104070 WO2022002213A1 (en) 2020-07-02 2021-07-01 Translation result display method and apparatus, and electronic device

Country Status (2)

Country Link
CN (1) CN113885973B (en)
WO (1) WO2022002213A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117270720A (en) * 2023-04-28 2023-12-22 荣耀终端有限公司 Page display method and electronic equipment

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023225947A1 (en) * 2022-05-26 2023-11-30 北京小米移动软件有限公司 Interface display method and apparatus and storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106933450A (en) * 2017-03-13 2017-07-07 联想(北京)有限公司 A kind of control method and electronic equipment
CN107408112A (en) * 2015-05-18 2017-11-28 谷歌公司 Coordinates user selected ci poem for translation selects the acquisition with the contextual information of selected word
CN107430480A (en) * 2015-01-14 2017-12-01 三星电子株式会社 The method of electronic equipment and in the electronic device processing information
CN108595445A (en) * 2018-04-23 2018-09-28 Oppo广东移动通信有限公司 Interpretation method, device and terminal
CN110119515A (en) * 2019-04-18 2019-08-13 珠海格力电器股份有限公司 Translation method, translation device, terminal and readable storage medium
CN110781688A (en) * 2019-09-20 2020-02-11 华为技术有限公司 Method and electronic device for machine translation
CN111680521A (en) * 2020-05-19 2020-09-18 北京搜狗科技发展有限公司 Translation processing method and device and translation processing device

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN206039075U (en) * 2016-09-14 2017-03-22 孙逸 Intelligence translation glasses
CN107153541B (en) * 2017-04-20 2020-07-03 北京小米移动软件有限公司 Browsing interaction processing method and device
CN111164983B (en) * 2018-05-09 2024-04-12 华为技术有限公司 The interconnection terminal lends local processing capability
CN109101498B (en) * 2018-07-23 2023-04-18 Oppo广东移动通信有限公司 Translation method and device and mobile terminal
CN109582976A (en) * 2018-10-15 2019-04-05 华为技术有限公司 A kind of interpretation method and electronic equipment based on voice communication
CN115017920A (en) * 2018-10-15 2022-09-06 华为技术有限公司 Translation method and electronic equipment
CN111221845A (en) * 2019-12-31 2020-06-02 华为技术有限公司 Cross-device information searching method and terminal device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107430480A (en) * 2015-01-14 2017-12-01 三星电子株式会社 The method of electronic equipment and in the electronic device processing information
CN107408112A (en) * 2015-05-18 2017-11-28 谷歌公司 Coordinates user selected ci poem for translation selects the acquisition with the contextual information of selected word
CN106933450A (en) * 2017-03-13 2017-07-07 联想(北京)有限公司 A kind of control method and electronic equipment
CN108595445A (en) * 2018-04-23 2018-09-28 Oppo广东移动通信有限公司 Interpretation method, device and terminal
CN110119515A (en) * 2019-04-18 2019-08-13 珠海格力电器股份有限公司 Translation method, translation device, terminal and readable storage medium
CN110781688A (en) * 2019-09-20 2020-02-11 华为技术有限公司 Method and electronic device for machine translation
CN111680521A (en) * 2020-05-19 2020-09-18 北京搜狗科技发展有限公司 Translation processing method and device and translation processing device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117270720A (en) * 2023-04-28 2023-12-22 荣耀终端有限公司 Page display method and electronic equipment

Also Published As

Publication number Publication date
CN113885973B (en) 2024-07-30
CN113885973A (en) 2022-01-04

Similar Documents

Publication Publication Date Title
JP7142783B2 (en) Voice control method and electronic device
CN113645351B (en) Application interface interaction method, electronic device and computer-readable storage medium
WO2021013158A1 (en) Display method and related apparatus
WO2020052529A1 (en) Method for quickly adjusting out small window in fullscreen display during video, graphic user interface and terminal
WO2021129326A1 (en) Screen display method and electronic device
WO2021000803A1 (en) Method for controlling small window of screen and related device
WO2020134869A1 (en) Electronic device operating method and electronic device
WO2021000881A1 (en) Screen splitting method and electronic device
EP4012544B1 (en) Split-screen processing method and terminal device
WO2022068483A1 (en) Application startup method and apparatus, and electronic device
WO2022017393A1 (en) Display interaction system, display method, and device
WO2021063098A1 (en) Touch screen response method, and electronic device
WO2022068819A1 (en) Interface display method and related apparatus
EP3958106B1 (en) Interface display method and electronic device
CN116069212B (en) Quick looking-up method for application card, electronic equipment and storage medium
WO2021078032A1 (en) User interface display method and electronic device
WO2021190524A1 (en) Screenshot processing method, graphic user interface and terminal
WO2022037726A1 (en) Split-screen display method and electronic device
CN115016697A (en) Screen projection method, computer device, readable storage medium, and program product
WO2022002213A1 (en) Translation result display method and apparatus, and electronic device
US20230236714A1 (en) Cross-Device Desktop Management Method, First Electronic Device, and Second Electronic Device
WO2023029916A1 (en) Annotation display method and apparatus, terminal device, and readable storage medium
WO2022135273A1 (en) Method for invoking capabilities of other devices, electronic device, and system
WO2023098417A1 (en) Interface display method and apparatus
WO2022143094A1 (en) Window page interaction method and apparatus, electronic device, and readable storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21834372

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21834372

Country of ref document: EP

Kind code of ref document: A1