You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@guacamole.apache.org by mike-jumper <gi...@git.apache.org> on 2017/01/31 06:40:27 UTC

[GitHub] incubator-guacamole-server pull request #57: GUACAMOLE-193: Take character a...

GitHub user mike-jumper opened a pull request:

    https://github.com/apache/incubator-guacamole-server/pull/57

    GUACAMOLE-193: Take character attributes into account when testing for visibility.

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/mike-jumper/incubator-guacamole-server fix-blank-rendering

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/incubator-guacamole-server/pull/57.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #57
    
----
commit fc6f36150f7163048238ba432eccef8895423ac5
Author: Michael Jumper <mj...@apache.org>
Date:   2017-01-31T06:00:29Z

    GUACAMOLE-193: Take character attributes into account when testing for visibility.

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-guacamole-server pull request #57: GUACAMOLE-193: Take character a...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/incubator-guacamole-server/pull/57


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] incubator-guacamole-server pull request #57: GUACAMOLE-193: Take character a...

Posted by jmuehlner <gi...@git.apache.org>.
Github user jmuehlner commented on a diff in the pull request:

    https://github.com/apache/incubator-guacamole-server/pull/57#discussion_r98610868
  
    --- Diff: src/terminal/terminal.c ---
    @@ -847,6 +847,45 @@ int guac_terminal_clear_range(guac_terminal* term,
     
     }
     
    +/**
    + * Returns whether the given character would be visible relative to the
    + * background of the given terminal.
    + *
    + * @param term
    + *     The guac_terminal to test the character against.
    + *
    + * @param c
    + *     The character being tested.
    + *
    + * @return
    + *     true if the given character is different from the terminal background,
    + *     false otherwise.
    + */
    +static bool guac_terminal_is_visible(guac_terminal* term,
    +        guac_terminal_char* c) {
    +
    +    /* Continuation characters are NEVER visible */
    +    if (c->value == GUAC_CHAR_CONTINUATION)
    +        return false;
    +
    +    /* Characters with glyphs are ALWAYS visible */
    +    if (guac_terminal_has_glyph(c->value))
    +        return true;
    +
    +    int background;
    +
    +    /* Determine actual background color of character */
    +    if (c->attributes.reverse != c->attributes.cursor)
    --- End diff --
    
    I'm not sure I understand what this check is about - comparing the reverse attribute to the cursor attribute?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---