"Attachment layout" of action is simply ignored! Why? - facebook-graph-api

I publish an OG action/object but the attachment layout of the action (which has been set to "Item") is simply ignored. On my timeline, I click on the date/time link to see the action in full details (along with the attachment)... but all I see is a box with object image in the center and the object title at the bottom:
------------------
| |
| |
| Image |
| |
| |
------------------
| Object Title |
------------------
Instead I expect to see a smaller image at the left side along with the title and other captions on the right side (like what "Item" layout preview is showing):
-----------------------------------------
| | Object Title |
| | Caption 1 |
| Image | Caption 2 |
| | Caption 3 |
| | Caption 4 |
-----------------------------------------
And the OG tags of my object page, hosted on my website, are correct (at least the Facebook OG Debugger says so!).
Does anyone know what I'm missing here?
Thank you,

Related

Django display related objects inside related objects in the admin

According to my assignment admin must be able to create Polls with Questions (create, delete, update) and Choices related to this questions. All of this should be displayed and changable on the same admin page.
Poll
|
|_question_1
| |
| |_choice_1(text)
| |
| |_choice_2
| |
| |_choice_3
|
|_question_2
| |
| |_choice_1
| |
| |_choice_2
| |
| |_choice_3
|
|_question_3
|
|_choice_1
|
|_choice_2
|
|_choice_3
Ok, it's not a problem to display one level of nesting like so on
class QuestionInline(admin.StackedInline):
model = Question
class PollAdmin(ModelAdmin):
inlines = [
QuestionInline,
]
But how to do to get the required poll design structure?
Check out this library it should provide the functionality.

Cascading actions with bookmarks in PowerBI

The problem is the following:
Let's consider 2 sets of images embedded in a PowerBI file .pbix:
Set 1: Img1, Img2
Set 2: Img3, Img4, Img5, Img6
For each combination of 2 images between the two sets, we want to set an action (to a bookmark) to display a corresponding visual.
So here, we have these combinations:
(Img1, Img3) -> display Viz1.3
(Img1, Img4) -> display Viz1.4
(Img1, Img5) -> display Viz1.5
(Img1, Img6) -> display Viz1.6
(Img2, Img3) -> display Viz2.3
(Img2, Img4) -> display Viz2.4
(Img2, Img5) -> display Viz2.5
(Img2, Img6) -> display Viz2.6
Let's suppose that we have selected (Img1, Img3) and then we select (click) Img2.
How can we keep the selection on Img3 in order to display Viz2.3 ?
Marco
Each image can, I'm pretty sure, only trigger one bookmark. If I'm reading right, I think you need to duplicate the images and hide/show according to the state of the display.
For example in the example above, if the display is Viz1.3 and you click image 2, the updates would be to the viz and to the images in set 2:
Viz1.3 -> Viz2.3
Img3.1 -> Img3.2
Img4.1 -> Img4.2
Img5.1 -> Img5.2
Img6.1 -> Img6.2
And if you updated from there by clicking Img4 to get to Viz2.4, you'd have to update the images in set one
Viz2.3 -> Viz2.4
Img1.3 -> Img1.4
Img2.3 -> Img2.4
So, ultimately, you'd need four version of each image in set one (one for each in set two) and two of each in set two (to match set one). And though you're only showing 6 at any given time, that's 16 which is twice as many as you have visuals. But if you have to have it that way for UX, then I can't think of another way to do it.
| Image | Bookmark |
|-----------|--------------|
| Img1.3 | Viz1.3 |
| Img1.4 | Viz1.4 |
| Img1.5 | Viz1.5 |
| Img1.6 | Viz1.6 |
| Img2.3 | Viz2.3 |
| Img2.4 | Viz2.4 |
| Img2.5 | Viz2.5 |
| Img2.6 | Viz2.6 |
| Img3.1 | Viz1.3 |
| Img3.2 | Viz2.3 |
| Img4.1 | Viz1.4 |
| Img4.2 | Viz2.4 |
| Img5.1 | Viz1.5 |
| Img5.2 | Viz2.5 |
| Img6.1 | Viz1.6 |
| Img6.2 | Viz2.6 |
Showing or hiding bookmarks by screen state

LibVncClient get operation system info

I use the libvncclient, to build a viewer, in which i try to integrate a specific hotkeys which do a bit of scripting, that are done as menu options, such as enable taskmanager,'run cmd' for window, and 'open terminal,'update repos' etc. I need to detect the operating system info, but i don't see anything to get this info from in rfb proto
rfbClient *client = new client();
if(!ConnectToRFBServer(client,client->serverHost,client->serverPort))
return FALSE;
if (!InitialiseRFBConnection(client))
return FALSE;
I looked trough the rfbclient.h and rfbClient structure doesn't hold any callback/or field that stores this info, as well as there is no apis for that it seems. But in rfc there is this thing https://www.rfc-editor.org/rfc/rfc6143#section-7.3.2
After receiving the ClientInit message, the server sends a ServerInit
message. This tells the client the width and height of the server's
framebuffer, its pixel format, and the name associated with the
desktop:
Richardson & Levine Informational [Page 11]
RFC 6143 The Remote Framebuffer Protocol March 2011
+--------------+--------------+------------------------------+
| No. of bytes | Type [Value] | Description |
+--------------+--------------+------------------------------+
| 2 | U16 | framebuffer-width in pixels |
| 2 | U16 | framebuffer-height in pixels |
| 16 | PIXEL_FORMAT | server-pixel-format |
| 4 | U32 | name-length |
| name-length | U8 array | name-string |
+--------------+--------------+------------------------------+
But it seems that libvnc doesn't handle that, is there any way that this info could be taken?

cucumber Repeat steps

I am learing cucumber and trying to write a feature file.
Following is my feature file.
Feature: Doctors handover Notes Module
Scenario: Search for patients on the bases of filter criteria
Given I am on website login page
When I put username, password and select database:
| Field | Value |
| username | test |
| password | pass |
| database | test|
Then I login to eoasis
Then I click on doctors hand over notes link
And I am on doctors handover notes page
Then I select sites, wards, onCallTeam, grades,potential Discharge, outstanding task,High priority:
| siteList | wardsList | onCallTeamList | gradesList | potentialDischargeCB | outstandingTasksCB | highPriorityCB |
| THE INFIRMARY | INFIRMARY WARD 9 - ASSESSMENT | null | null | null | null | null |
| THE INFIRMARY | INFIRMARY WARD 9 - ASSESSMENT | GENERAL MEDICINE | null | null | null | null |
| THE INFIRMARY | INFIRMARY WARD 9 - ASSESSMENT | GENERAL MEDICINE | CONSULTANT | null | null | null |
| THE INFIRMARY | INFIRMARY WARD 9 - ASSESSMENT | GENERAL MEDICINE | CONSULTANT | true | null | null |
| THE INFIRMARY | INFIRMARY WARD 9 - ASSESSMENT | GENERAL MEDICINE | CONSULTANT | true | true | null |
| THE INFIRMARY | INFIRMARY WARD 9 - ASSESSMENT | GENERAL MEDICINE | CONSULTANT | true | true | true |
Then I click on search button
Then I should see search results
I want to repeat last three steps like I select the search criteria then click on search button and then check search result. So how should I break this feature file. if I use scenario outline then there would be two different scenarios One for login and one for search criteria. Is that fine? Will the session will maintain in that case? Whats the best way to write such feature file.
Or is this a right way to write?
I don't think we can have multiple example sets in a Scenario Outline.
Most of the scenario steps in the example is too procedural to have its own step.
The first three steps could be reduced to something like.
Given I am logged into eoasis as a <user>
Code in the step definition, which could make calls to a separate login method that could take care of updating entering the username, password and selecting database.
Another rule is to avoid statements like "When I click the doctor's handover link". The keyword to avoid here being click. Today its a click, tomorrow it could be drop down or a button. So the focus should be on the functional expectation of the user, which is viewing the handover notes. So we modify this to
When I view the doctor's handover notes link
To summarize, this is how I would write this test.
Scenario Outline: Search for patients on the basis of filter criteria
Given I am logged into eoasis as a <user>
When I view the doctor's handover notes link
And I select sites, wards, onCallTeam, grades, potential Discharge, outstanding task, High priority
And perform a search
Then I should see the search results
Examples:
|sites |wards |onCallTeam |grades |potential Discharge |outstanding task |High priority|
| THE INFIRMARY | INFIRMARY WARD 9 - ASSESSMENT | null | null | null | null | null |
This really is the wrong way to write features. This feature is very declarative, its all about HOW you do something. What a feature should do is explain WHY you are doing something.
Another bad thing this feature does is mix up the details of two different operations, signing in, and searching for patients. Write a feature for each one e.g.
Feature: Signing in
As a doctor
I want my patients data to only be available if I sign in
So I ensure their confidentiality
Scenario: Sign in
Given I am a doctor
When I sign in
Then I should be signed in
Feature: Search for patients
Explain why searching for patients gives value to the doctor
...
You should focus on the name of the feature and the bit at the top that explains why this has value first. If you do that well then the scenarios are much easier to write (look how simple my sign in scenario is).
The art of writing features is doing this bit well, so that you end up with simple scenarios.

How should I implement sub-windows in my OpenGL viewport?

How should I implement sub-windows in my OpenGL viewport? Inside my viewport, I want to reserve some space on the left for labels, and some space around the edges as a border. I've got all the coordinates figured out and everything is displaying properly. My problem is clipping the things in one subwindow that are spilling over into the others. I can't seem to figure out what the OpenGL 3.3, core context way of doing things is. Is it to
use per-vertex clipping?
a scissor test?
a stencil test?
associate a framebuffer with different parts of my window?
Which commands should I be looking at?
Before I spend time writing a full answer, I would like you to confirm that this is what you were describing in your original question:
*---------------------------------------*
| ------------------------------------- |
| | | | |
| | | | |
| | | | |
|C| A | B |C|
| | | | |
| | | | |
| |___|_______________________________| |
*---------------------------------------*
A = Labels
B = Main Window
C = Border