Information display method, device and storage medium
By identifying the anchor object and automatically determining the display position and copy display mode of the bubble message based on its position information, the problem in the existing technology that the difference in the display position and copy length of the bubble message affects development efficiency is solved, and an automated development process is realized.
Patent Information
- Application Number
- CN202111385787.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-22
- Publication Date
- 2024-09-20
- Estimated Expiration
- 2041-11-22
AI Technical Summary
In the existing technology, differences in the display position and copy length of bubble messages require developers to individually adapt and develop, affecting the overall development efficiency of the application.
By identifying the anchor object and based on its position information on the terminal screen, the display position and copy display method of the bubble message are automatically determined, avoiding developers from making separate adaptations.
It improves development efficiency and realizes the automatic calculation of the display position and copy display mode of bubble messages, without the need for developers to manually adjust.
Smart Images

Figure CN114077372B
Abstract
Description
Technical Field
[0001] The embodiments of the present disclosure relate to the field of computer technology, and in particular, to an information display method, device, and storage medium. Background Art
[0002] With the improvement of terminal device hardware performance and the continuous advancement of artificial intelligence technology, more and more applications (Application, APP for short) are running on terminal devices.
[0003] Currently, in the relevant technology, when a user operates an application, the application will respond to the current user operation and display a message prompt box on the terminal device for the user to view. The message prompt box will not get the focus and will automatically display a message after a period of time. This message prompt box is called a bubble message.
[0004] However, due to differences in the display position of bubble messages and the length of bubble text, developers are usually required to develop separate adaptations for the display position and display method of bubble messages, which affects the overall development efficiency of the application. Summary of the invention
[0005] The embodiments of the present disclosure provide an information display method, device and storage medium to overcome the problem in the prior art that developers are required to individually adapt the display position and display method of bubble messages, which affects the overall development efficiency.
[0006] In a first aspect, an embodiment of the present disclosure provides an information display method, including:
[0007] Identify anchor objects;
[0008] Determine the display position and display mode of the bubble message corresponding to the anchor object according to the position information of the anchor object on the terminal screen;
[0009] In response to the operation on the anchor object, the bubble message is displayed on the terminal screen in the display position and display mode.
[0010] In a second aspect, an embodiment of the present disclosure provides an information display device, including:
[0011] Recognition module, used to identify anchor objects;
[0012] A processing module, configured to determine a display position and a display mode of a bubble message corresponding to the anchor object according to the position information of the anchor object on the terminal screen;
[0013] The display module is used to display the bubble message on the terminal screen in the display position and display mode in response to the operation on the anchor object.
[0014] In a third aspect, an embodiment of the present disclosure provides an electronic device, including: a processor and a memory;
[0015] The memory stores computer-executable instructions;
[0016] The processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the information display method described in the first aspect and various possible designs of the first aspect.
[0017] In a fourth aspect, an embodiment of the present disclosure provides a computer-readable storage medium, in which computer execution instructions are stored. When a processor executes the computer execution instructions, the information display method described in the first aspect and various possible designs of the first aspect is implemented.
[0018] In a fifth aspect, an embodiment of the present disclosure provides a computer program product, including a computer program, which, when executed by a processor, implements the information display method described in the first aspect and various possible designs of the first aspect.
[0019] The information display method, device and storage medium provided in this embodiment identify the anchor object and determine the display position and text display method of the bubble message based on the relative position of the anchor object and the terminal screen. This solution can automatically calculate the display position and text display method of the bubble message without the need for developers to perform separate adaptation development, thereby improving development efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0021] Figure 1 A schematic diagram of a scenario of an information display method provided by an embodiment of the present disclosure;
[0022] Figure 2 Schematic diagram of the information display method provided in the embodiment of the present disclosure Figure 1 ;
[0023] Figure 3 Schematic diagram of the information display method provided in the embodiment of the present disclosure Figure 2 ;
[0024] Figure 4 Schematic diagram of display of bubble message provided in the embodiment of the present disclosure Figure 1 ;
[0025] Figure 5 Schematic diagram of display of bubble message provided in the embodiment of the present disclosure Figure 2 ;
[0026] Figure 6 Schematic diagram of display of bubble message provided in the embodiment of the present disclosure Figure 3 ;
[0027] Figure 7 A structural block diagram of an information display device provided by an embodiment of the present disclosure;
[0028] Figure 8 A structural block diagram of a processing module provided for the disclosed embodiment;
[0029] Fig. 9 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0030] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.
[0031] With the development of terminal technology, various terminal devices have been widely used in people's lives. At present, many terminal devices use the Android system, which provides a bubble message prompt function. That is, after the user operates an application on the terminal device, the application will respond to the current user operation and display a message prompt box on the terminal device for the user to view. The message prompt box will not get the focus and will automatically close after a period of time. Due to the uncertainty of the relative position and text length of the bubble message, developers are usually required to develop separate adaptations for different bubble message display positions and display methods, which affects development efficiency.
[0032] In order to solve the above technical problems, the present disclosure provides the following technical concept: based on the relative position of the anchor object and the terminal screen, the display position and text display method of the bubble message are automatically determined, without the need for developers to perform separate adaptation development, which can improve development efficiency.
[0033] refer to Figure 1 , Figure 1 A schematic diagram of a scenario of an information display method provided by an embodiment of the present disclosure. Figure 1As shown, the scenario provided in this embodiment includes a terminal device 101 and a server 102. The terminal device 101 can be installed on a device such as a mobile phone, a tablet computer, and a personal computer. This embodiment does not impose any special restrictions on the implementation of the terminal device 101, as long as the terminal device 101 can interact with the user for input and output. The server 102 can be a single server or a cluster of several servers.
[0034] It should be noted that the terminal device involved in the present disclosure can be a wireless terminal or a wired terminal. A wireless terminal can be a device that provides voice and / or other business data connectivity to a user, a handheld device with a wireless connection function, or other processing devices connected to a wireless modem. A wireless terminal can communicate with one or more core network devices via a radio access network (Radio Access Network, referred to as RAN). A wireless terminal can be a mobile terminal, such as a mobile phone (or "cellular" phone) and a computer with a mobile terminal, for example, a portable, pocket-sized, handheld, computer-built-in or vehicle-mounted mobile device, which exchanges language and / or data with a radio access network. For another example, a wireless terminal can also be a personal communication service (Personal Communication Service, referred to as PCS) phone, a cordless phone, a Session Initiation Protocol (Session Initiation Protocol, referred to as SIP) phone, a wireless local loop (Wireless Local Loop, referred to as WLL) station, a personal digital assistant (Personal Digital Assistant, referred to as PDA) and other devices. The wireless terminal may also be referred to as a system, a subscriber unit, a subscriber station, a mobile station, a mobile station, a remote station, a remote terminal, an access terminal, a user terminal, a user agent, a user device or user equipment, without limitation herein. Optionally, the terminal device may also be a smart watch, a tablet computer or other device.
[0035] refer to Figure 2 , Figure 2 Schematic diagram of the information display method provided in the embodiment of the present disclosure Figure 1The method of this embodiment can be applied to the terminal device shown in the figure, and can also be applied to other electronic devices, which is not limited in the present disclosure. The information display method includes:
[0036] S201: Identify anchor objects.
[0037] In the disclosed embodiment, an anchor object is a type of hyperlink in an application program, and a specified object can be linked to through the anchor object, for example, a new file or any other message element.
[0038] The user can click on the anchor object to connect to other new web pages; or the user can click on the anchor object to open and display a new message.
[0039] For example, a user clicks an icon (this icon is an anchor object) in an instant messaging software to link and open a mini-program page or a game page corresponding to the icon.
[0040] S202: Determine the display position and display mode of the bubble message corresponding to the anchor object according to the position information of the anchor object on the terminal screen.
[0041] In an embodiment of the present disclosure, a calculation model for calculating the display position and display mode of the bubble message can be determined based on the distance of the anchor object in the terminal screen relative to the edge of the terminal screen, and the display position and display mode of the bubble message can be determined based on the calculation model.
[0042] S203: In response to the operation on the anchor object, display the bubble message on the terminal screen in the display position and display mode.
[0043] In an embodiment of the present disclosure, the user triggers the anchor object through mouse click, touch control or visual control, and sends a request to the server based on the triggering of the anchor object, so that the server sends a bubble message to the terminal device and displays the bubble message on the terminal screen in a corresponding display position and display method.
[0044] From the above description, it can be seen that this embodiment identifies the anchor object and determines the display position and text display method of the bubble message based on the relative position of the anchor object and the terminal screen. This solution can automatically calculate the display position and text display method of the bubble message without the need for developers to perform separate adaptation development, thereby improving development efficiency.
[0045] refer to Figure 3 , Figure 3 Schematic diagram of the information display method provided in the embodiment of the present disclosure Figure 2This embodiment describes in detail how to determine the display position and display mode of the bubble message corresponding to the anchor object according to the position information of the anchor object on the terminal screen, as detailed as follows:
[0046] S301: Determine the offset of the anchor object from the left edge of the terminal screen.
[0047] S302: Determine a calculation model for calculating the display position and display mode of the bubble message according to the offset.
[0048] S303: Calculate the display position and text display mode of the bubble message according to the calculation model.
[0049] In a possible implementation of the present disclosure, in step S302, if the offset is less than a first preset threshold, the calculation model for determining the bubble message display position and display mode is a first calculation model, wherein the first calculation model includes:
[0050] According to the distance between the left edge of the anchor object and the left edge of the terminal screen and the preset minimum offset of the message prompt box of the bubble message from the left or right side of the terminal screen, the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is calculated; the corresponding specific formula is:
[0051] xoffset=anchorx-leftorrightoffset;
[0052] Wherein, xoffset is the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object; anchorx is the distance between the left edge of the anchor object and the left edge of the terminal screen; leftorrightoffset is the minimum offset of the preset message prompt box of the bubble message from the left or right side of the terminal screen;
[0053] The distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message is calculated according to the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, the width of the anchor object and the width of the arrow of the message prompt box of the bubble message; the corresponding specific formula is:
[0054]
[0055] Among them, leftMargin is the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message; anchorviewwidth is the width of the anchor object; arrowviewwidth is the width of the arrow of the message prompt box of the bubble message.
[0056] Among them, Figure 4 As shown, when the offset is less than the first preset threshold, the anchor object is located in the left area of the terminal screen.
[0057] Correspondingly, in step S303, the display position and text display mode of the bubble message are calculated according to the calculation model, including: determining the display position of the bubble message according to the distance between the left edge of the message prompt box of the bubble message obtained by the first calculation model and the left edge of the anchor object; determining the text display mode of the bubble message according to the distance between the arrow of the message prompt box of the bubble message obtained by the first calculation model and the left edge of the message prompt box of the bubble message.
[0058] The distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is determined as the left edge starting position of the display position of the bubble message.
[0059] Among them, according to the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message, the arrow of the message prompt box is displayed as the text display mode of the bubble message.
[0060] From the above description, it can be seen that when the anchor object is located in the left area of the terminal screen, the bubble message display position and display method automatically calculated according to the first calculation model are more reasonable and fit the user experience.
[0061] In another possible implementation of the present disclosure, in step S302, if the offset is greater than a second preset threshold, the calculation model for determining the bubble message display position and display mode is a second calculation model, wherein the second calculation model includes:
[0062] The distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is calculated according to the text width of the bubble message, the width of the terminal screen, the distance between the left edge of the anchor object and the left edge of the terminal screen, and the preset minimum offset of the message prompt box of the bubble message from the left or right side of the terminal screen; the corresponding specific formula is:
[0063] xoffset=textwidth-(screenwidth-anchorx)+leftorrightoffset;
[0064] Among them, xoffset is the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object; textwidth is the text width of the bubble message; screenwidth is the width of the terminal screen; anchorx is the distance between the left edge of the anchor object and the left edge of the terminal screen; leftorrightoffset is the minimum offset of the preset message prompt box of the bubble message from the left or right side of the terminal screen;
[0065] The distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message is calculated according to the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, the width of the anchor object and the width of the arrow of the message prompt box of the bubble message; the corresponding specific formula is:
[0066]
[0067] Among them, leftMargin is the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message; anchorviewwidth is the width of the anchor object; arrowviewwidth is the width of the arrow of the message prompt box of the bubble message.
[0068] Among them, Figure 5 As shown, when the offset is greater than the second preset threshold, the anchor object is located in the right area of the terminal screen.
[0069] Accordingly, in step S303, the display position and text display mode of the bubble message are calculated according to the calculation model, including:
[0070] The display position of the bubble message is determined according to the distance between the left edge of the message prompt box of the bubble message obtained by the second computing model and the left edge of the anchor object; the text display method of the bubble message is determined according to the distance between the arrow of the message prompt box of the bubble message obtained by the second computing model and the left edge of the message prompt box of the bubble message.
[0071] From the above description, it can be seen that when the anchor object is located in the right area of the terminal screen, the bubble message display position and display method are automatically calculated according to the second calculation model. The display position and display method are more reasonable and fit the user experience.
[0072] In another possible implementation of the present disclosure, in step S302, if the offset is less than or equal to the first preset threshold and greater than or equal to the second preset threshold, the calculation model for determining the bubble message display position and display mode is a third calculation model, wherein the third calculation model includes:
[0073] According to the text width of the bubble message and the width of the anchor object, the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is calculated; the corresponding specific formula is:
[0074]
[0075] Among them, xoffset is the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object; the textwidth is the text width of the bubble message; and anchorviewwidth is the width of the anchor object.
[0076] The arrow of the message prompt box of the bubble message is located at the center of the text of the bubble message.
[0077] Among them, Figure 6 As shown, when the offset is less than or equal to the first preset threshold and greater than or equal to the second preset threshold, the anchor object is located in the middle area of the terminal screen.
[0078] Accordingly, in step S303, the display position and text display mode of the bubble message are calculated according to the calculation model, including:
[0079] The display position of the bubble message is determined based on the distance between the left edge of the message prompt box of the bubble message obtained by the second calculation model and the left edge of the anchor object; the text display method of the bubble message is determined based on the arrow of the message prompt box of the bubble message being located at the center of the text of the bubble message.
[0080] From the above description, it can be seen that when the anchor object is located in the middle area of the terminal screen, the bubble message display position and display method are automatically calculated according to the third calculation model. The display position and display method are more reasonable and fit the user experience.
[0081] Corresponding to the information display method of the above embodiment, Figure 7 This is a structural block diagram of an information display device provided by an embodiment of the present disclosure. For ease of explanation, only the parts related to the embodiment of the present disclosure are shown. Figure 7 The device includes: an identification module 701, a processing module 702 and a display module 703.
[0082] Wherein, the recognition module 701 is used to recognize the anchor object;
[0083] The processing module 702 is used to determine the display position and display mode of the bubble message corresponding to the anchor object according to the position information of the anchor object on the terminal screen;
[0084] The display module 703 is used to display the bubble message on the terminal screen in the display position and display mode in response to the operation on the anchor object.
[0085] From the above description, it can be seen that by identifying the anchor object and determining the display position and text display method of the bubble message based on the relative position of the anchor object and the terminal screen, this solution can automatically calculate the display position and text display method of the bubble message, without the need for developers to perform separate adaptation development, thereby improving development efficiency.
[0086] refer to Figure 8 , Figure 8 The structural block diagram of the processing module provided for the disclosed embodiment. In one or more embodiments of the present disclosure, the processing module 702 includes: a determination unit 7021, a model processing unit 7022 and a display processing unit 7023.
[0087] The determining unit 7021 is used to determine the offset of the anchor point object from the left edge of the terminal screen;
[0088] A model processing unit 7022 is used to determine a calculation model for calculating the display position and display mode of the bubble message according to the offset;
[0089] The display processing unit 7023 is used to calculate the display position and text display mode of the bubble message according to the calculation model.
[0090] In one or more embodiments of the present disclosure, the model processing unit 7022 is specifically used to determine that the calculation model of the bubble message display position and display mode is the first calculation model if the offset is less than a first preset threshold.
[0091] In one or more embodiments of the present disclosure, the first computing model includes:
[0092] According to the distance between the left edge of the anchor object and the left edge of the terminal screen and the preset minimum offset of the message prompt box of the bubble message from the left or right side of the terminal screen, the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is calculated; the corresponding specific formula is:
[0093] xoffset=anchorx-leftorrightoffset;
[0094] Wherein, xoffset is the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object; anchorx is the distance between the left edge of the anchor object and the left edge of the terminal screen; leftorrightoffset is the minimum offset of the preset message prompt box of the bubble message from the left or right side of the terminal screen;
[0095] The distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message is calculated according to the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, the width of the anchor object and the width of the arrow of the message prompt box of the bubble message; the corresponding specific formula is:
[0096]
[0097] Among them, leftMargin is the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message; anchorviewwidth is the width of the anchor object; arrowviewwidth is the width of the arrow of the message prompt box of the bubble message.
[0098] In one or more embodiments of the present disclosure, the display processing unit 7023 is specifically used to determine the display position of the bubble message according to the distance between the left edge of the message prompt box of the bubble message obtained by the first computing model and the left edge of the anchor object; and determine the text display method of the bubble message according to the distance between the arrow of the message prompt box of the bubble message obtained by the first computing model and the left edge of the message prompt box of the bubble message.
[0099] In one or more embodiments of the present disclosure, the model processing unit 7022 is specifically used to determine that the calculation model of the bubble message display position and display mode is the second calculation model if the offset is greater than a second preset threshold.
[0100] In one or more embodiments of the present disclosure, the second calculation model includes:
[0101] The distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is calculated according to the text width of the bubble message, the width of the terminal screen, the distance between the left edge of the anchor object and the left edge of the terminal screen, and the preset minimum offset of the message prompt box of the bubble message from the left or right side of the terminal screen; the corresponding specific formula is:
[0102] xoffset=textwidth-(screenwidth-anchorx)+leftorrightoffset;
[0103] Among them, xoffset is the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object; textwidth is the text width of the bubble message; screenwidth is the width of the terminal screen; anchorx is the distance between the left edge of the anchor object and the left edge of the terminal screen; leftorrightoffset is the minimum offset of the preset message prompt box of the bubble message from the left or right side of the terminal screen;
[0104] The distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message is calculated according to the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, the width of the anchor object and the width of the arrow of the message prompt box of the bubble message; the corresponding specific formula is:
[0105]
[0106] Among them, leftMargin is the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message; anchorviewwidth is the width of the anchor object; arrowviewwidth is the width of the arrow of the message prompt box of the bubble message.
[0107] In one or more embodiments of the present disclosure, the model processing unit 7022 is specifically used to determine that the calculation model of the bubble message display position and display mode is a third calculation model if the offset is less than or equal to the first preset threshold and greater than or equal to the second preset threshold.
[0108] In one or more embodiments of the present disclosure, the third computing model includes:
[0109] According to the text width of the bubble message and the width of the anchor object, the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is calculated; the corresponding specific formula is:
[0110]
[0111] Among them, xoffset is the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object; the textwidth is the text width of the bubble message; and anchorviewwidth is the width of the anchor object.
[0112] The arrow of the message prompt box of the bubble message is located at the center of the text of the bubble message.
[0113] The device provided in this embodiment can be used to execute the technical solution of the above method embodiment. Its implementation principle and technical effect are similar, and this embodiment will not be repeated here.
[0114] In order to implement the above embodiment, the embodiment of the present disclosure also provides an electronic device.
[0115] refer to Fig. 9 , which shows a schematic diagram of the structure of an electronic device 900 suitable for implementing the embodiment of the present disclosure, and the electronic device 900 may be a terminal device or a server. The terminal device may include but is not limited to mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, personal digital assistants (PDAs), tablet computers (Portable Android Devices, PADs), portable multimedia players (PMPs), vehicle terminals (such as vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Fig. 9 The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0116] like Fig. 9 As shown, the electronic device 900 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 901, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 902 or a program loaded from a storage device 908 to a random access memory (RAM) 903. In the RAM 903, various programs and data required for the operation of the electronic device 900 are also stored. The processing device 901, the ROM 902, and the RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.
[0117] Typically, the following devices may be connected to the I / O interface 905: input devices 906 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; output devices 907 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; storage devices 908 including, for example, a magnetic tape, a hard disk, etc.; and communication devices 909. The communication device 909 may allow the electronic device 900 to communicate with other devices wirelessly or by wire to exchange data. Although Fig. 9 The electronic device 900 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.
[0118] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device 909, or installed from a storage device 908, or installed from a ROM 902. When the computer program is executed by the processing device 901, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.
[0119] It should be noted that the computer-readable medium disclosed above may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0120] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0121] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device executes the method shown in the above embodiment.
[0122] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0123] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0124] The units involved in the embodiments described in the present disclosure may be implemented by software or hardware. The name of a unit does not limit the unit itself in some cases. For example, the first acquisition unit may also be described as a "unit for acquiring at least two Internet Protocol addresses".
[0125] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0126] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0127] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.
[0128] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.
[0129] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.
Claims
1. An information display method, characterized in that: include: Identify an anchor object, where the anchor object is a type of hyperlink in an application program; Determine the offset of the anchor object from the left edge of the terminal screen, determine a calculation model for calculating the display position and display mode of the bubble message according to the offset, and calculate the display position and text display mode of the bubble message according to the calculation model, wherein the calculation model is used to determine the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object and to determine the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message; In response to an operation on the anchor object, displaying the bubble message on the terminal screen at the display position and in the display mode; The step of determining a calculation model for calculating the display position and display mode of the bubble message according to the offset, and calculating the display position and text display mode of the bubble message according to the calculation model, comprises: if the offset is less than a first preset threshold, determining that the calculation model for calculating the display position and display mode of the bubble message is a first calculation model; Determine the display position of the bubble message by obtaining the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object according to the first calculation model, the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, the width of the anchor object, and the width of the arrow of the message prompt box of the bubble message; determine the text display method of the bubble message by obtaining the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message obtained by the first calculation model.
2. The method according to claim 1, characterized in that The first computing model comprises: Calculate the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object according to the distance between the left edge of the anchor object and the left edge of the terminal screen and the minimum offset of the message prompt box of the preset bubble message from the left or right side of the terminal screen; The distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message is calculated based on the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, the width of the anchor object and the width of the arrow of the message prompt box of the bubble message.
3. The method according to claim 1, characterized in that The step of determining a calculation model for calculating a display position and a display mode of the bubble message according to the offset includes: If the offset is greater than a second preset threshold, the calculation model for determining the bubble message display position and display mode is the second calculation model.
4. The method according to claim 3, characterized in that The second calculation model comprises: The distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is calculated according to the text width of the bubble message, the width of the terminal screen, the distance between the left edge of the anchor object and the left edge of the terminal screen, and the preset minimum offset of the message prompt box of the bubble message from the left or right side of the terminal screen; According to the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, the width of the anchor object and the width of the arrow of the message prompt box of the bubble message, the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message is calculated.
5. The method according to claim 1, characterized in that The step of determining a calculation model for calculating a display position and a display mode of the bubble message according to the offset includes: If the offset is less than or equal to the first preset threshold and greater than or equal to the second preset threshold, the calculation model for determining the bubble message display position and display mode is the third calculation model.
6. The method according to claim 5, characterized in that The third calculation model comprises: According to the text width of the bubble message and the width of the anchor object, the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object is calculated; The arrow of the message prompt box of the bubble message is located at the center of the text of the bubble message.
7. An information display device, characterized in that: include: An identification module, used for identifying an anchor object, wherein the anchor object is a type of hyperlink in an application program; A processing module, used to determine the offset of the anchor object from the left edge of the terminal screen, determine a calculation model for calculating the display position and display mode of the bubble message according to the offset, and calculate the display position and text display mode of the bubble message according to the calculation model, wherein the calculation model is used to determine the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, and to determine the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message; A display module, configured to display the bubble message on a terminal screen in the display position and display mode in response to an operation on the anchor object; The processing module determines a calculation model for calculating the display position and display mode of the bubble message according to the offset, and calculates the display position and text display mode of the bubble message according to the calculation model, specifically including: if the offset is less than a first preset threshold, determining the calculation model for calculating the display position and display mode of the bubble message as the first calculation model; determining the display position of the bubble message according to the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object obtained by the first calculation model, the distance between the left edge of the message prompt box of the bubble message and the left edge of the anchor object, the width of the anchor object, and the width of the arrow of the message prompt box of the bubble message; determining the text display mode of the bubble message according to the distance between the arrow of the message prompt box of the bubble message and the left edge of the message prompt box of the bubble message obtained by the first calculation model.
8. An electronic device, characterized in that: include: Processor and memory; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor executes the information display method according to any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and when the processor executes the computer-executable instructions, the information display method according to any one of claims 1 to 6 is implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the method for displaying information according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Prompt box display method and terminal
CN104142786A
Word paraphrase box display method and electronic device
CN107765949A
Face detection information display method, device and equipment and storage medium
CN109670422A
