Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linebreaking #76

Open
wants to merge 43 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
e6ef7e9
Add simple line breaking support
mzn723 Mar 13, 2016
272a2af
Adding full justification for the alignment feature -Does not work pr…
mzn723 Apr 4, 2016
6607903
Fix right alignment
BalqeesAlBeloshi Aug 7, 2016
bb2e375
Minor adjustments in comments, indentation and enums
BalqeesAlBeloshi Jun 27, 2016
5ccdd4f
Fix memory initialisation in breaking_action
khalidalqassabi Aug 7, 2016
dbe5adb
Fix the run problem automake (subdir-objectes)
khalidalqassabi Aug 7, 2016
9b3cca8
Fix the documentation
khalidalqassabi Aug 2, 2016
dae5f43
Clean things up a bit
khaledhosny Aug 7, 2016
1999532
Fix docs
khaledhosny Aug 7, 2016
ea8d3e7
Avoid memory leak in case of early return
khaledhosny Aug 7, 2016
6819592
Use UCDN line break macros directly
khaledhosny Aug 7, 2016
4d0c056
Simplify
khaledhosny Aug 7, 2016
1b0ef29
Fix AppVeyor build
khaledhosny Aug 7, 2016
75da2ff
Put these defines closer to where they are used
khaledhosny Aug 7, 2016
b8b6506
Move new members to the end of the struct
khaledhosny Aug 7, 2016
d30ea54
Don’t bother if there is only one character
khaledhosny Aug 7, 2016
f7df184
Minor
khaledhosny Aug 7, 2016
121b0ca
Reduce variable scope and avoid dangerous casts
khaledhosny Aug 7, 2016
b1dd1ad
Don’t do line breaking if line width is negative
khaledhosny Aug 7, 2016
ffc754f
Fix build
khaledhosny Aug 8, 2016
1263ffa
Add a simple test for line breaking
khaledhosny Sep 18, 2016
c24c154
Minor cleanup
khaledhosny Sep 18, 2016
1e52009
Minor
khaledhosny Sep 18, 2016
16624ec
Minor
khaledhosny Sep 18, 2016
801c1ee
Don’t hard code space character
khaledhosny Sep 18, 2016
fde7873
RAQM_ALIGNMENT_FULL → RAQM_ALIGNMENT_JUSTIFY
khaledhosny Sep 18, 2016
595baf7
Use switch statement
khaledhosny Sep 18, 2016
6e2c644
Split line breaking to its own function
khaledhosny Sep 18, 2016
80baecc
Don’t use x offset when calculating line width
khaledhosny Sep 18, 2016
f71f693
Rename and fix since tags
khaledhosny Apr 15, 2017
8ab0e6a
Minor
khaledhosny Apr 15, 2017
6885a09
Deuglify this
khaledhosny Apr 15, 2017
b77daad
Move this logic closer to where it is needed
khaledhosny Apr 15, 2017
e3ea8b0
Don’t ignore allocation failures
khaledhosny Apr 15, 2017
a388e22
Minor
khaledhosny Apr 15, 2017
735f918
Fix line metrics
khaledhosny Sep 18, 2016
c118604
Make line breaking a bit more robust
khaledhosny Apr 15, 2017
65b74e2
Move alignment handling to its own function
khaledhosny Apr 15, 2017
40038a1
Add direction agonistic start/end alignment
khaledhosny Apr 15, 2017
352bf8c
Switch to libunibreak for finding possible breaks
khaledhosny Apr 16, 2017
31dcb55
Remove unused ucdn submodule
khaledhosny Apr 16, 2017
121904f
Make testing line breaks a bit more reliable
khaledhosny Apr 16, 2017
3b00a74
Build libunibreak
khaledhosny Apr 16, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ os:
install:
- set PATH=C:\msys64\usr\bin;C:\msys64\mingw64\bin;%PATH%
- appveyor DownloadFile "https://raw.githubusercontent.com/swig/cccl/master/cccl"
- appveyor DownloadFile "https://github.com/adah1972/libunibreak/releases/download/libunibreak_4_0/libunibreak-4.0.tar.gz"
- call "%VS140COMNTOOLS%\..\..\VC\vcvarsall.bat" %PLATFORM%
- appveyor-retry C:\msys64\usr\bin\pacman -Syuu --needed --noconfirm --noprogressbar --ask=127
- appveyor-retry C:\msys64\usr\bin\pacman -S --noconfirm autoconf automake libtool gtk-doc mingw-w64-x86_64-pkg-config mingw-w64-x86_64-harfbuzz mingw-w64-x86_64-fribidi mingw-w64-x86_64-freetype
Expand All @@ -14,6 +15,9 @@ build_script:
- set LD=cccl
- set PKG_CONFIG_PATH=%PKG_CONFIG_PATH%:/mingw64/lib/pkgconfig
- bash -c "mv cccl /usr/bin"
- bash -c "tar xf libunibreak-4.0.tar.gz && cd libunibreak-4.0 && ./configure --prefix=/usr/local && make && make install"
- set UNIBREAK_CFLAGS=-I/usr/local/include
- set UNIBREAK_LIBS="-L/usr/local/lib/ -lunibreak"
- bash -c "exec 0</dev/null; ./autogen.sh"
- bash -c "exec 0</dev/null; ./configure"
- bash -c "exec 0</dev/null; make CFLAGS='/W4 /WX /wd4068'"
Expand Down
Empty file added .gitmodules
Empty file.
5 changes: 5 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ matrix:
include:
- os: linux
script:
- export UNIBREAK_CFLAGS=-I/usr/include UNIBREAK_LIBS=-lunibreak
- ./autogen.sh
- ./configure --enable-gtk-doc
- make check
Expand All @@ -16,12 +17,15 @@ matrix:
- os: linux
compiler: clang
script:
- export UNIBREAK_CFLAGS=-I/usr/include UNIBREAK_LIBS=-lunibreak
- ./autogen.sh
- ./configure
- make check

- os: osx
before_install:
- wget https://github.com/adah1972/libunibreak/releases/download/libunibreak_4_0/libunibreak-4.0.tar.gz
- (tar xf libunibreak-4.0.tar.gz && cd libunibreak-4.0 && ./configure && make && sudo make install)
- export HOMEBREW_NO_AUTO_UPDATE=1
- brew install freetype fribidi glib gtk-doc
- brew install --without-icu4c --without-glib --without-cairo
Expand All @@ -41,4 +45,5 @@ addons:
- libharfbuzz-dev
- libfribidi-dev
- libglib2.0-dev
- libunibreak-dev
- gtk-doc-tools
1 change: 1 addition & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ PKG_PROG_PKG_CONFIG([0.20])
AX_PKG_CHECK_MODULES(FREETYPE, [freetype2 >= 12.0.6], [])
AX_PKG_CHECK_MODULES(HARFBUZZ, [], harfbuzz)
AX_PKG_CHECK_MODULES(FRIBIDI, [], fribidi)
AX_PKG_CHECK_MODULES(UNIBREAK, [], libunibreak)
PKG_CHECK_MODULES(GLIB, glib-2.0, have_glib=true, have_glib=false)

_save_libs="$LIBS"
Expand Down
3 changes: 3 additions & 0 deletions docs/raqm-sections.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ raqm_set_text
raqm_set_text_utf8
raqm_set_par_direction
raqm_set_language
raqm_set_width
raqm_set_alignment
raqm_set_freetype_face
raqm_set_freetype_face_range
raqm_set_freetype_load_flags
Expand All @@ -17,5 +19,6 @@ raqm_index_to_position
raqm_position_to_index
raqm_t
raqm_direction_t
raqm_alignment_t
raqm_glyph_t
</SECTION>
2 changes: 2 additions & 0 deletions src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,15 @@ libraqm_la_LIBADD = \
$(FREETYPE_LIBS) \
$(HARFBUZZ_LIBS) \
$(FRIBIDI_LIBS) \
$(UNIBREAK_LIBS) \
$(WARN_LDLAGS) \
$(NULL)

libraqm_la_CPPFLAGS = \
$(FREETYPE_CFLAGS) \
$(HARFBUZZ_CFLAGS) \
$(FRIBIDI_CFLAGS) \
$(UNIBREAK_CFLAGS) \
$(WARN_CFLAGS) \
$(NULL)

Expand Down
Loading