Commit Graph

34 Commits

Author SHA1 Message Date
Hermet Park 02a50da5d6 template: fix a invalid coordinates code generation.
fix a side effect of localizing floats.

_posix_fp() uses static stringbuffer.
If this function is called multiple times in printf(),
previous buffer data will be invalid.

we are calling this for x, y twice in one func.
2016-07-19 20:18:12 +09:00
Jean Guyomarc'h e910826ade template: don't localize floats in the edje editor
Summary:
Enventor live edit would generate invalid code with
the french locale.
Indeed, french uses a comma (",") as the decimal point,
instead of the dot. With localization enabled, printf()
would automatically localized the floating point,
introducing a comma in the edje code where a dot is
expected...

To avoid this, we now enclose the floats we don't want
to be localized (use the implicit POSIX local: with a dot)
in a function that looks the current locale and replace
the decimal point with a dot.

Test Plan:
(1) Without the patch, call LC_ALL=C enventor and see live
    edit if correct.
(2) Without the patch, call LC_ALL=fr_FR.UTF-8 envetor and
    see live edit generate invalid edje code.
(3) Apply the patch, and repeat steps (1) and (2) and observe
    that both cases now success.

Reviewers: Hermet

Differential Revision: https://phab.enlightenment.org/D4146
2016-07-14 13:58:06 +09:00
Hermet Park e58c6c7600 live_edit: fix a broken functionality.
edc_parser was unintentionally changed while multi-files support.
2016-07-04 13:59:39 +09:00
Hermet Park 53f4b3c28c support the new type vector. 2016-06-20 13:42:36 +09:00
Hermet Park 4da3778f80 removed redundant code 2016-06-05 13:09:52 +09:00
Bowon Ryu 2698280453 template: set uninitialized value
Summary: fix static analyzer warning

Reviewers: Hermet, Jaehyun_Cho

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D4001
2016-06-02 11:57:30 +09:00
Jaehyun Cho b769398911 template: Fix to insert template code to the correct place.
Previously, template code was inserted before the closing bracket.
Now, template code is inserted after the closing bracket.

Test Plan
1. Open basic.edc.
2. Put mouse cursor the end of the line 18.
3. Press Ctrl + t to insert template code of image part.
2016-05-31 14:25:33 +09:00
Jaehyun Cho 1dd3d5c465 template: Fix line count of textblock part inserted in live edit mode.
Previously, line count was not correct after textblock part is inserted
in live edit mode.
Now, line count is correctly calculated after textblock part is inserted
in live edit mode.

Test Plan
1. Insert textblock part in live edit mode.
2. Check max line number.
2016-05-31 14:12:21 +09:00
Hermet Park 98d9cf4cb0 live_edit: fix the logic to support fixed size.
previous logic was corrupted at some point.
2016-05-29 01:41:52 +09:00
Jaehyun Cho ada36237e9 template: Fix warnings. 2016-05-17 00:41:36 +09:00
Taehyub Kim 6ba3339d25 template: fix the fixed condition for relative_to
Summary:
fix the fixed condifion for relative_to.
the condition was wrong, so I fixed it.

Test Plan:
1. Launch Enventor
2. Click a Live Edit Item
3. Check fixed_w and fixed_h
4. Insert the Live Edit Item

Reviewers: Hermet, Jaehyun_Cho, NikaWhite

Differential Revision: https://phab.enlightenment.org/D3943
2016-05-16 23:30:26 +09:00
Taehyub 5194059b40 live_edit: Add new feature about setting relative_to among the exist parts
Summary:
Add new interface feature about setting relative_to to make relationship esaily
between part and part. Now, we can make the relationship using just mouse interface.

Test Plan:
1. launch enventor
2. add live edit item using live edit toolbar
3. drag the item to the another part
4. move a control point that you want to make a relationship to the another part edge
5. and then relative_to ctxpopup is shown
6. select the relative_to item in the ctxpopup
7. insert the live edit item with double click
8. check the inserted code whether it is make relationship or not

Reviewers: Jaehyun_Cho, NikaWhite, Hermet

Reviewed By: Hermet

Differential Revision: https://phab.enlightenment.org/D3936
2016-05-11 21:57:51 +09:00
Taehyub Kim 876903f918 template: fix the error of line position when inserting group template
Summary:
fix the error operation of group template insertion.
The line position would be broken after inserting group template.
so I fixed it.

Test Plan:
1. launch enventor
2. insert group template using Ctrl + T
3. check the line position of source code whether it is corrected or not

Reviewers: Hermet, Jaehyun_Cho, NikaWhite

Differential Revision: https://phab.enlightenment.org/D3908
2016-04-22 15:44:18 +09:00
Taehyub Kim c1aae66795 live_edit: support direction key events for moving live edit item
Summary:
before, we cannot move the live edit item using direction key.
now we can modify it using direction key.

@T3356

Test Plan:
1. launch enventor
2. insert a live edit item
3. move the item using direction key

Reviewers: Jaehyun_Cho, NikaWhite, Hermet

Differential Revision: https://phab.enlightenment.org/D3862
2016-04-18 14:04:28 +09:00
Taehyub Kim 3b038768f5 template: improve adding template of image resource do not duplicate
Summary:
when we insert image template or live view item,
the template code of image resource will be duplicated.
so, I added the code checking template image resource not to be duplicate

Test Plan:
1. launch enventor
2. add image part twice using ctrl + t or live view item
3. see the images block has an ENVENTOR_EMBEDDED_LOGO.png

Reviewers: Hermet, Jaehyun_Cho, NikaWhite

Differential Revision: https://phab.enlightenment.org/D3851
2016-04-01 16:33:34 +09:00
Yongheon, Shin 842341bea2 [T3267] improve part name for more formal naming rule
Summary:
Current generated part name from the live edit is too unfamiliar with users.
We need to improve for more formal naming rule like,
ex) rect_xxxx
    image_xxxx
    swallow_xxxx

Test Plan:
1. Open Enventor
2. Add rect, image, swllow, text, textblock, spacer

Reviewers: Hermet, Jaehyun_Cho

Reviewed By: Jaehyun_Cho

Subscribers: Jaehyun_Cho, Hermet

Differential Revision: https://phab.enlightenment.org/D3793
2016-03-17 14:38:28 +09:00
taehyub ad35ab32aa template: select the random name after inserting live view part
Summary:
select the random name after inserting live view part or template part.

Test Plan:
1. insert a part using Live View
2. see the selection region of random name of Live View
3. insert a templte using Ctrl + t
4. see the selection region of random name of template

@T3014

Reviewers: Hermet, Jaehyun_Cho, NikaWhite

Differential Revision: https://phab.enlightenment.org/D3743
2016-03-04 16:32:58 +09:00
taehyub 26570d64c0 template: Fix undo error by correcting cursor position
Summary:
There is a memorizing cursor in wrong position, it cause undo error.
If insert the description template, undo operation is not working correctly.

@fix

Test Plan:
1. press ctrl + t in the part, then insert description part
2. press ctrl + z, undo the code
3. see the normal operation

Reviewers: Hermet, Jaehyun_Cho, NikaWhite

Differential Revision: https://phab.enlightenment.org/D3760
2016-03-04 16:19:42 +09:00
Jaehyun Cho 5ec2cb8599 template: Fix to set edc changed in template_insert().
Set edc changed in template_insert() to save template insertion.

Test Plan:
1. write a part. (e.g. rect { "rect2";)
2. insert desc template (ctrl + t)
2. close edc

When edc is closed without saving after inserting template, warning
popup should appear.
2016-02-29 17:38:53 +09:00
taehyub f2cc727146 make group, description and program tempalte code compilable
Summary: make group, description and program tempalte code compilable

Test Plan:
1. insert template code using ctrl + t
2. see the name of the template and checkt the compile error.

Reviewers: Jaehyun_Cho, Hermet

Subscribers: NikaWhite

Differential Revision: https://phab.enlightenment.org/D3613
2016-01-29 16:41:59 +09:00
Jaehyun Cho e984d2bb4e template: Fix incorrect template insertion inside LazEDC block
Since LazEDC block types were not recognized for template insertion,
inserted template type inside LazEDC block was not correct.
(e.g. inside desc { })
Now LazEDC block types are considered for template insertion by Ctrl+T.
2016-01-27 15:14:27 +09:00
Mykyta Biliavskyi fbc8111b56 Template: fix indention for generated "styles" block.
@fix T2973
2015-12-30 14:35:25 +09:00
Mykyta Biliavskyi 39ddc2da33 Templates: fix indention for generated "images" block
fix T2971
2015-12-30 11:36:09 +09:00
Mykyta Biliavskyi c8fdf43e9a Fix compilation warnings for enventor library. 2015-09-15 17:39:51 +00:00
ChunEon Park 12fc464bd9 template: update live edit generation code for new edc syntax. 2015-06-30 16:46:34 +09:00
Mykyta Biliavskyi 533994772f Fix compiler warnings.
Fix -Wuninitialized flag warnings.
2015-06-24 13:12:20 +09:00
ChunEon Park cdab9f0a5d clean up code for supporting dllexport in win32. 2015-02-28 15:13:23 +09:00
ChunEon Park 96d4919a6b enable ENVENTOR BETA API in configure. 2015-02-28 14:50:17 +09:00
Michelle Legrand 05a848fddd lib: add export/import for libraries on Windows
Summary: Exporting/Importing Enventor dll for Win32.

Differential Revision: https://phab.enlightenment.org/D2040
2015-02-28 14:33:18 +09:00
ChunEon Park 5e8f437df5 fix all annoying warnings. 2015-02-27 17:26:02 +09:00
Jaehyun Cho 46d1017df7 template: Fix cursor position when insert image description and textblock style.
Fix the cursor position when image description and textblock style are inserted
with image part and textblock part.
2015-02-12 23:01:37 +09:00
Jaehyun Cho 2e80073cfd template: Enable to insert image description and textblock style.
Enable to insert image description and textblock style when image part and
textblock part are inserted.
Previously, those are inserted only if parts are inserted by the live edit.
2015-02-11 20:21:27 +09:00
Jaehyun Cho 98a9eca6c5 live_edit: Fix T1785 to restore live edit
Summary:
Fix T1785 to restore live edit
         @fix

Reviewers: Hermet

Maniphest Tasks: T1785

Differential Revision: https://phab.enlightenment.org/D1650
2014-11-12 16:44:19 +09:00
ChunEon Park e5927b37eb library support.
current enventor apis are under beta apis.
im notice you these apis could be changed soon.
2014-09-30 23:56:16 +09:00