Skip to content

Commit

Permalink
8323880: Caret rendered at wrong position in case of a click event on…
Browse files Browse the repository at this point in the history
… RTL text

Reviewed-by: kcr, hmeda
  • Loading branch information
Jay Bhaskar committed Feb 16, 2024
1 parent 2754939 commit 1fb56e3
Showing 1 changed file with 12 additions and 0 deletions.
Expand Up @@ -293,7 +293,19 @@ class FontCascade : public CanMakeWeakPtr<FontCascade> {

bool advancedTextRenderingMode() const
{
#if !PLATFORM(JAVA)
return m_fontDescription.textRenderingMode() != TextRenderingMode::OptimizeSpeed;
#else
//The current implementation of complex text rendering path on the Java platform is experiencing
//side effects. We need to align with WebKit 616.1 standards.
auto textRenderingMode = m_fontDescription.textRenderingMode();
if (textRenderingMode == TextRenderingMode::GeometricPrecision || textRenderingMode == TextRenderingMode::OptimizeLegibility)
return true;
if (textRenderingMode == TextRenderingMode::OptimizeSpeed)
return false;

return false;
#endif
}

bool computeEnableKerning() const
Expand Down

4 comments on commit 1fb56e3

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jaybhaskar
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/backport jfx21u

@openjdk
Copy link

@openjdk openjdk bot commented on 1fb56e3 Feb 16, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jaybhaskar Could not automatically backport 1fb56e33 to openjdk/jfx21u due to conflicts in the following files:

  • modules/javafx.web/src/main/native/Source/WebCore/platform/graphics/FontCascade.h

Please fetch the appropriate branch/commit and manually resolve these conflicts by using the following commands in your personal fork of openjdk/jfx21u. Note: these commands are just some suggestions and you can use other equivalent commands you know.

# Fetch the up-to-date version of the target branch
$ git fetch --no-tags https://git.openjdk.org/jfx21u.git master:master

# Check out the target branch and create your own branch to backport
$ git checkout master
$ git checkout -b backport-jaybhaskar-1fb56e33

# Fetch the commit you want to backport
$ git fetch --no-tags https://git.openjdk.org/jfx.git 1fb56e333bc65860cc1abeebd1cbb01cd8b8e5f3

# Backport the commit
$ git cherry-pick --no-commit 1fb56e333bc65860cc1abeebd1cbb01cd8b8e5f3
# Resolve conflicts now

# Commit the files you have modified
$ git add files/with/resolved/conflicts
$ git commit -m 'Backport 1fb56e333bc65860cc1abeebd1cbb01cd8b8e5f3'

Once you have resolved the conflicts as explained above continue with creating a pull request towards the openjdk/jfx21u with the title Backport 1fb56e333bc65860cc1abeebd1cbb01cd8b8e5f3.

Below you can find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit 1fb56e33 from the openjdk/jfx repository.

The commit being backported was authored by Jay Bhaskar on 16 Feb 2024 and was reviewed by Kevin Rushforth and Hima Bindu Meda.

Thanks!

@kevinrushforth
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo: that should be "jfx22u" (not jfx21u)

Please sign in to comment.